Class JpaUser
java.lang.Object
org.opencastproject.security.impl.jpa.JpaUser
- All Implemented Interfaces:
User
JPA-annotated user object.
-
Constructor Summary
ConstructorsConstructorDescriptionJpaUser()No-arg constructor needed by JPAJpaUser(String username, String password, JpaOrganization organization, String provider, boolean manageable, Set<JpaRole> roles) Constructs a user with the specified username, password, provider and roles.JpaUser(String username, String password, JpaOrganization organization, String name, String email, String provider, boolean manageable) Constructs a user with the specified username, password, name, email and provider.JpaUser(String username, String password, JpaOrganization organization, String name, String email, String provider, boolean manageable, Set<JpaRole> roles) Constructs a user with the specified username, password, name, email, provider and roles. -
Method Summary
Modifier and TypeMethodDescriptionbooleangetEmail()Gets the user's email address.getId()getName()Gets the user's name.Returns the user's organization identifier.Gets this user's clear text password.Gets the provider where the user is coming from.getRoles()Gets the user's roles.Gets this user's unique account name.inthashCode()booleanReturns whether the user is in a specific role.booleanReturnstrueif this user object can be managed by Opencast.voidvoidsetManageable(boolean isManageable) voidsetProvider(String provider) toString()
-
Constructor Details
-
JpaUser
public JpaUser()No-arg constructor needed by JPA -
JpaUser
public JpaUser(String username, String password, JpaOrganization organization, String name, String email, String provider, boolean manageable) Constructs a user with the specified username, password, name, email and provider.- Parameters:
username- the usernamepassword- the passwordorganization- the organizationname- the nameemail- the emailprovider- the providermanageable- whether the user is manageable
-
JpaUser
public JpaUser(String username, String password, JpaOrganization organization, String provider, boolean manageable, Set<JpaRole> roles) Constructs a user with the specified username, password, provider and roles.- Parameters:
username- the usernamepassword- the passwordorganization- the organizationprovider- the providermanageable- whether the user is manageableroles- the roles
-
JpaUser
public JpaUser(String username, String password, JpaOrganization organization, String name, String email, String provider, boolean manageable, Set<JpaRole> roles) Constructs a user with the specified username, password, name, email, provider and roles.- Parameters:
username- the usernamepassword- the passwordorganization- the organizationname- the nameemail- the emailprovider- the providermanageable- whether the user is manageableroles- the roles
-
-
Method Details
-
getId
-
setId
-
getPassword
Gets this user's clear text password.- Specified by:
getPasswordin interfaceUser- Returns:
- the user account's password
-
getUsername
Description copied from interface:UserGets this user's unique account name.- Specified by:
getUsernamein interfaceUser- Returns:
- the account name
- See Also:
-
hasRole
Description copied from interface:UserReturns whether the user is in a specific role. -
getOrganization
Description copied from interface:UserReturns the user's organization identifier.- Specified by:
getOrganizationin interfaceUser- Returns:
- the organization
- See Also:
-
getRoles
Description copied from interface:UserGets the user's roles. For anonymous users, this will return Anonymous. -
equals
-
hashCode
public int hashCode() -
toString
-
getName
Description copied from interface:UserGets the user's name. -
getEmail
Description copied from interface:UserGets the user's email address. -
getProvider
Description copied from interface:UserGets the provider where the user is coming from.- Specified by:
getProviderin interfaceUser- Returns:
- the provider where the user is coming from.
-
setProvider
-
isManageable
public boolean isManageable()Description copied from interface:UserReturnstrueif this user object can be managed by Opencast.- Specified by:
isManageablein interfaceUser- Returns:
trueif this user is manageable
-
setManageable
public void setManageable(boolean isManageable)
-