Package com.atlassian.bamboo.user
Class DefaultBambooUser
java.lang.Object
com.atlassian.bamboo.user.DefaultBambooUser
- All Implemented Interfaces:
BambooUser
,com.atlassian.user.Entity
,com.atlassian.user.User
,Serializable
,Principal
,org.acegisecurity.userdetails.UserDetails
- See Also:
-
Field Summary
Modifier and TypeFieldDescriptionstatic final String
The name of the default admin group in Bamboo that's created on setup.static final String
Fields inherited from interface com.atlassian.bamboo.user.BambooUser
BOTH_PREF, DEFAULT_NOTIFICATION_PREFERENCE, DEFAULT_TRANSPORT_PREFERENCE, EMAIL_PREF, IM_PREF, MULTIPART_EMAIL, NONE_PREF, TEXT_EMAIL
-
Constructor Summary
ConstructorDescriptionDefaultBambooUser
(@NotNull com.atlassian.user.User user, @NotNull Supplier<org.acegisecurity.GrantedAuthority[]> authoritiesSupplier) DefaultBambooUser
(@NotNull com.atlassian.user.User user, @NotNull Supplier<org.acegisecurity.GrantedAuthority[]> authoritiesSupplier, @Nullable AccessToken accessToken) DefaultBambooUser
(com.atlassian.user.User user) Deprecated.since 6.6.0. -
Method Summary
Modifier and TypeMethodDescriptionboolean
@Nullable AccessToken
If user has been authenticated by access token returns meta-data of token.@NotNull org.acegisecurity.GrantedAuthority[]
getEmail()
@Nullable String
Returns the user's jabber address for IMsgetName()
Returns the user's preferences for how they receive notificationsReturns the user's preference for the format of emailscom.atlassian.user.User
getUser()
Returns the user, which contains the user's detailsint
hashCode()
boolean
boolean
boolean
boolean
toString()
-
Field Details
-
DEFAULT_USERS_GROUP
- See Also:
-
DEFAULT_ADMIN_GROUP
The name of the default admin group in Bamboo that's created on setup. This should NOT be used to check permissions, as the users can configure other groups to be admin, and using it will introduce security vulnerabilities. If a list of admin groups is needed, useBambooPermissionManager.getAdminGroups()
.- See Also:
-
-
Constructor Details
-
DefaultBambooUser
Deprecated.since 6.6.0. UseDefaultBambooUser(User, GrantedAuthority[])
-
DefaultBambooUser
public DefaultBambooUser(@NotNull @NotNull com.atlassian.user.User user, @NotNull @NotNull Supplier<org.acegisecurity.GrantedAuthority[]> authoritiesSupplier) -
DefaultBambooUser
public DefaultBambooUser(@NotNull @NotNull com.atlassian.user.User user, @NotNull @NotNull Supplier<org.acegisecurity.GrantedAuthority[]> authoritiesSupplier, @Nullable @Nullable AccessToken accessToken)
-
-
Method Details
-
getJabberAddress
Description copied from interface:BambooUser
Returns the user's jabber address for IMs- Specified by:
getJabberAddress
in interfaceBambooUser
- Returns:
- jabber address.
-
getNotificationPreference
Description copied from interface:BambooUser
Returns the user's preferences for how they receive notifications- Specified by:
getNotificationPreference
in interfaceBambooUser
- Returns:
- notification preference.
-
getNotificationTransportPreference
Description copied from interface:BambooUser
Returns the user's preference for the format of emails- Specified by:
getNotificationTransportPreference
in interfaceBambooUser
- Returns:
- notification transport preference.
-
getUser
public com.atlassian.user.User getUser()Description copied from interface:BambooUser
Returns the user, which contains the user's details- Specified by:
getUser
in interfaceBambooUser
- Returns:
- user.
-
getName
-
getFullName
- Specified by:
getFullName
in interfacecom.atlassian.user.User
-
getEmail
- Specified by:
getEmail
in interfacecom.atlassian.user.User
-
hashCode
public int hashCode() -
equals
-
getAuthorities
@NotNull public @NotNull org.acegisecurity.GrantedAuthority[] getAuthorities()- Specified by:
getAuthorities
in interfaceorg.acegisecurity.userdetails.UserDetails
-
getPassword
- Specified by:
getPassword
in interfaceorg.acegisecurity.userdetails.UserDetails
-
getUsername
- Specified by:
getUsername
in interfaceorg.acegisecurity.userdetails.UserDetails
-
isAccountNonExpired
public boolean isAccountNonExpired()- Specified by:
isAccountNonExpired
in interfaceorg.acegisecurity.userdetails.UserDetails
-
isAccountNonLocked
public boolean isAccountNonLocked()- Specified by:
isAccountNonLocked
in interfaceorg.acegisecurity.userdetails.UserDetails
-
isCredentialsNonExpired
public boolean isCredentialsNonExpired()- Specified by:
isCredentialsNonExpired
in interfaceorg.acegisecurity.userdetails.UserDetails
-
isEnabled
public boolean isEnabled()- Specified by:
isEnabled
in interfacecom.atlassian.user.User
- Specified by:
isEnabled
in interfaceorg.acegisecurity.userdetails.UserDetails
-
getAccessToken
Description copied from interface:BambooUser
If user has been authenticated by access token returns meta-data of token. Otherwise null.- Specified by:
getAccessToken
in interfaceBambooUser
- Returns:
- access token
-
toString
-