Package com.atlassian.crowd.embedded.api
Interface User
- All Superinterfaces:
Comparable<User>
,Principal
- All Known Subinterfaces:
TimestampedUser
,User
,UserWithAttributes
,UserWithAttributes
- All Known Implementing Classes:
BaseImmutableUser
,DelegatingUserWithAttributes
,DelegatingUserWithAttributes
,ImmutableTimestampedUser
,ImmutableTimestampedUserWithAttributes
,ImmutableUser
,ImmutableUser
,ImmutableUserWithAttributes
,InternalUser
,InternalUserWithAttributes
,LDAPUserWithAttributes
,UserEntity
,UserTemplate
,UserTemplateWithAttributes
,UserTemplateWithCredentialAndAttributes
Represents a user.
-
Method Summary
Modifier and TypeMethodDescriptionint
CompareTo must be compatible with the equals() and hashCode() methodsboolean
Implementations must ensure equality based on getDirectoryId() and case-insensitive getName().long
int
hashCode()
Implementations must produce a hashcode based on getDirectoryId() and case-insensitive getName().boolean
isActive()
default boolean
Returns if the user is already technically deleted.
-
Method Details
-
getDirectoryId
long getDirectoryId()- Returns:
- id of the directory in which the User is stored.
-
isActive
boolean isActive()- Returns:
true
if and only if the user is allowed to authenticate.
-
getEmailAddress
String getEmailAddress()- Returns:
- email address of the user.
-
getDisplayName
String getDisplayName()- Returns:
- display name (eg. full name) of the user, must never be null.
-
equals
Implementations must ensure equality based on getDirectoryId() and case-insensitive getName(). -
hashCode
int hashCode()Implementations must produce a hashcode based on getDirectoryId() and case-insensitive getName(). -
compareTo
CompareTo must be compatible with the equals() and hashCode() methods- Specified by:
compareTo
in interfaceComparable<User>
-
isMarkedAsDeleted
default boolean isMarkedAsDeleted()Returns if the user is already technically deleted. Products may decide to deactivate users rather than delete. This method is to let Crowd know that such user should not be deleted again.
-