Class JPAUser
- java.lang.Object
-
- org.apache.syncope.core.persistence.jpa.entity.AbstractEntity
-
- org.apache.syncope.core.persistence.jpa.entity.AbstractGeneratedKeyEntity
-
- org.apache.syncope.core.persistence.jpa.entity.AbstractAny<P>
-
- org.apache.syncope.core.persistence.jpa.entity.AbstractGroupableRelatable<User,UMembership,UPlainAttr,AnyObject,URelationship>
-
- org.apache.syncope.core.persistence.jpa.entity.user.JPAUser
-
- All Implemented Interfaces:
Serializable,Any<UPlainAttr>,Attributable<UPlainAttr>,Entity,GroupableRelatable<User,UMembership,UPlainAttr,AnyObject,URelationship>,Account,User
- Direct Known Subclasses:
JPAJSONUser
@Entity public class JPAUser extends AbstractGroupableRelatable<User,UMembership,UPlainAttr,AnyObject,URelationship> implements User
- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from class org.apache.syncope.core.persistence.jpa.entity.AbstractEntity
LOG
-
Fields inherited from interface org.apache.syncope.core.persistence.api.entity.Entity
EMAIL_PATTERN, ID_PATTERN, ID_REGEX
-
-
Constructor Summary
Constructors Constructor Description JPAUser()
-
Method Summary
-
Methods inherited from class org.apache.syncope.core.persistence.jpa.entity.AbstractGroupableRelatable
getMembership, getPlainAttr, getPlainAttr, getPlainAttrs, getPlainAttrs, getPlainAttrs, getRelationships, getRelationships, remove
-
Methods inherited from class org.apache.syncope.core.persistence.jpa.entity.AbstractAny
getCreationContext, getCreationDate, getCreator, getLastChangeContext, getLastChangeDate, getLastModifier, getRealm, setCreationContext, setCreationDate, setCreator, setLastChangeContext, setLastChangeDate, setLastModifier, setRealm
-
Methods inherited from class org.apache.syncope.core.persistence.jpa.entity.AbstractGeneratedKeyEntity
getKey, setKey
-
Methods inherited from class org.apache.syncope.core.persistence.jpa.entity.AbstractEntity
checkImplementationType, checkType, equals, hashCode, toString
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.apache.syncope.core.persistence.api.entity.Any
getCreationContext, getCreationDate, getCreator, getLastChangeContext, getLastChangeDate, getLastModifier, getRealm, setCreationContext, setCreationDate, setCreator, setLastChangeContext, setLastChangeDate, setLastModifier, setRealm
-
Methods inherited from interface org.apache.syncope.core.persistence.api.entity.Attributable
getPlainAttr, getPlainAttrs, remove
-
Methods inherited from interface org.apache.syncope.core.persistence.api.entity.GroupableRelatable
getMembership, getPlainAttr, getPlainAttrs, getPlainAttrs, getRelationships, getRelationships
-
-
-
-
Field Detail
-
TABLE
public static final String TABLE
- See Also:
- Constant Field Values
-
TYPEREF
protected static final TypeReference<List<String>> TYPEREF
-
password
protected String password
-
plainAttrs
@Valid protected @Valid List<JPAUPlainAttr> plainAttrs
-
status
protected String status
-
token
protected String token
-
tokenExpireTime
protected OffsetDateTime tokenExpireTime
-
cipherAlgorithm
protected CipherAlgorithm cipherAlgorithm
-
passwordHistory
protected String passwordHistory
-
failedLogins
protected Integer failedLogins
Subsequent failed logins.
-
username
@NotNull(message="Blank username") protected @NotNull(message="Blank username") String username
Username/Login.
-
lastLoginDate
protected OffsetDateTime lastLoginDate
Last successful login date.
-
changePwdDate
protected OffsetDateTime changePwdDate
Change password date.
-
suspended
protected Boolean suspended
-
mustChangePassword
protected Boolean mustChangePassword
-
resources
protected List<JPAExternalResource> resources
Provisioning external resources.
-
auxClasses
protected List<JPAAnyTypeClass> auxClasses
-
relationships
@Valid protected @Valid List<JPAURelationship> relationships
-
memberships
@Valid protected @Valid List<JPAUMembership> memberships
-
securityQuestion
protected JPASecurityQuestion securityQuestion
-
securityAnswer
protected String securityAnswer
-
linkedAccounts
@Valid protected @Valid List<JPALinkedAccount> linkedAccounts
-
-
Method Detail
-
getType
public AnyType getType()
- Specified by:
getTypein interfaceAny<UPlainAttr>
-
setType
public void setType(AnyType type)
- Specified by:
setTypein interfaceAny<UPlainAttr>
-
add
public boolean add(ExternalResource resource)
- Specified by:
addin interfaceAny<UPlainAttr>
-
getResources
public List<? extends ExternalResource> getResources()
- Specified by:
getResourcesin interfaceAny<UPlainAttr>
-
getPassword
public String getPassword()
- Specified by:
getPasswordin interfaceAccount
-
setEncodedPassword
public void setEncodedPassword(String password, CipherAlgorithm cipherAlgorithm)
- Specified by:
setEncodedPasswordin interfaceAccount
-
setPassword
public void setPassword(String password)
- Specified by:
setPasswordin interfaceAccount
-
getCipherAlgorithm
public CipherAlgorithm getCipherAlgorithm()
- Specified by:
getCipherAlgorithmin interfaceAccount
-
setCipherAlgorithm
public void setCipherAlgorithm(CipherAlgorithm cipherAlgorithm)
- Specified by:
setCipherAlgorithmin interfaceAccount
-
canDecodeSecrets
public boolean canDecodeSecrets()
- Specified by:
canDecodeSecretsin interfaceAccount
-
add
public boolean add(UPlainAttr attr)
- Specified by:
addin interfaceAttributable<UPlainAttr>
-
internalGetPlainAttrs
protected List<? extends UPlainAttr> internalGetPlainAttrs()
- Specified by:
internalGetPlainAttrsin classAbstractGroupableRelatable<User,UMembership,UPlainAttr,AnyObject,URelationship>
-
getStatus
public String getStatus()
- Specified by:
getStatusin interfaceAny<UPlainAttr>- Overrides:
getStatusin classAbstractAny<UPlainAttr>
-
setStatus
public void setStatus(String status)
- Specified by:
setStatusin interfaceAny<UPlainAttr>- Overrides:
setStatusin classAbstractAny<UPlainAttr>
-
generateToken
public void generateToken(int tokenLength, int tokenExpireTime)- Specified by:
generateTokenin interfaceUser
-
removeToken
public void removeToken()
- Specified by:
removeTokenin interfaceUser
-
getTokenExpireTime
public OffsetDateTime getTokenExpireTime()
- Specified by:
getTokenExpireTimein interfaceUser
-
checkToken
public boolean checkToken(String token)
- Specified by:
checkTokenin interfaceUser
-
hasTokenExpired
public boolean hasTokenExpired()
- Specified by:
hasTokenExpiredin interfaceUser
-
addToPasswordHistory
public void addToPasswordHistory(String password)
- Specified by:
addToPasswordHistoryin interfaceUser
-
removeOldestEntriesFromPasswordHistory
public void removeOldestEntriesFromPasswordHistory(int n)
- Specified by:
removeOldestEntriesFromPasswordHistoryin interfaceUser
-
getPasswordHistory
public List<String> getPasswordHistory()
- Specified by:
getPasswordHistoryin interfaceUser
-
getChangePwdDate
public OffsetDateTime getChangePwdDate()
- Specified by:
getChangePwdDatein interfaceUser
-
setChangePwdDate
public void setChangePwdDate(OffsetDateTime changePwdDate)
- Specified by:
setChangePwdDatein interfaceUser
-
getFailedLogins
public Integer getFailedLogins()
- Specified by:
getFailedLoginsin interfaceUser
-
setFailedLogins
public void setFailedLogins(Integer failedLogins)
- Specified by:
setFailedLoginsin interfaceUser
-
getLastLoginDate
public OffsetDateTime getLastLoginDate()
- Specified by:
getLastLoginDatein interfaceUser
-
setLastLoginDate
public void setLastLoginDate(OffsetDateTime lastLoginDate)
- Specified by:
setLastLoginDatein interfaceUser
-
getUsername
public String getUsername()
- Specified by:
getUsernamein interfaceAccount
-
setUsername
public void setUsername(String username)
- Specified by:
setUsernamein interfaceAccount
-
setSuspended
public void setSuspended(Boolean suspended)
- Specified by:
setSuspendedin interfaceAccount
-
isSuspended
public Boolean isSuspended()
- Specified by:
isSuspendedin interfaceAccount
-
setMustChangePassword
public void setMustChangePassword(boolean mustChangePassword)
- Specified by:
setMustChangePasswordin interfaceUser
-
isMustChangePassword
public boolean isMustChangePassword()
- Specified by:
isMustChangePasswordin interfaceUser
-
getSecurityQuestion
public SecurityQuestion getSecurityQuestion()
- Specified by:
getSecurityQuestionin interfaceUser
-
setSecurityQuestion
public void setSecurityQuestion(SecurityQuestion securityQuestion)
- Specified by:
setSecurityQuestionin interfaceUser
-
getSecurityAnswer
public String getSecurityAnswer()
- Specified by:
getSecurityAnswerin interfaceUser
-
setSecurityAnswer
public void setSecurityAnswer(String securityAnswer)
- Specified by:
setSecurityAnswerin interfaceUser
-
add
public boolean add(AnyTypeClass auxClass)
- Specified by:
addin interfaceAny<UPlainAttr>
-
getAuxClasses
public List<? extends AnyTypeClass> getAuxClasses()
- Specified by:
getAuxClassesin interfaceAny<UPlainAttr>
-
add
public boolean add(URelationship relationship)
- Specified by:
addin interfaceGroupableRelatable<User,UMembership,UPlainAttr,AnyObject,URelationship>
-
getRelationship
public Optional<? extends URelationship> getRelationship(RelationshipType relationshipType, String otherEndKey)
- Specified by:
getRelationshipin interfaceGroupableRelatable<User,UMembership,UPlainAttr,AnyObject,URelationship>
-
getRelationships
public List<? extends URelationship> getRelationships()
- Specified by:
getRelationshipsin interfaceGroupableRelatable<User,UMembership,UPlainAttr,AnyObject,URelationship>
-
add
public boolean add(UMembership membership)
- Specified by:
addin interfaceGroupableRelatable<User,UMembership,UPlainAttr,AnyObject,URelationship>
-
remove
public boolean remove(UMembership membership)
- Specified by:
removein interfaceGroupableRelatable<User,UMembership,UPlainAttr,AnyObject,URelationship>
-
getMemberships
public List<? extends UMembership> getMemberships()
- Specified by:
getMembershipsin interfaceGroupableRelatable<User,UMembership,UPlainAttr,AnyObject,URelationship>
-
add
public boolean add(LinkedAccount account)
-
getLinkedAccount
public Optional<? extends LinkedAccount> getLinkedAccount(String resource, String connObjectKeyValue)
- Specified by:
getLinkedAccountin interfaceUser
-
getLinkedAccounts
public List<? extends LinkedAccount> getLinkedAccounts(String resource)
- Specified by:
getLinkedAccountsin interfaceUser
-
getLinkedAccounts
public List<? extends LinkedAccount> getLinkedAccounts()
- Specified by:
getLinkedAccountsin interfaceUser
-
-