public class

BasicTypedTypeAvatarService

extends Object
implements TypeAvatarService
java.lang.Object
   ↳ com.atlassian.jira.avatar.types.BasicTypedTypeAvatarService
Known Direct Subclasses

Summary

Public Constructors
BasicTypedTypeAvatarService(Avatar.Type type, AvatarManager avatarManager, AvatarAccessPolicy policy)
Public Methods
boolean canUserCreateAvatar(ApplicationUser remoteUser, String owningObjectId)
Return information if user can add avatar to given subject.
Avatar createAvatar(ApplicationUser remoteUser, String owningObjectId, AvatarImageDataProvider imageDataProvider)
Adds new avatar to given subject with provided image data - with permissions of given remote user.
Avatar getAvatar(ApplicationUser remoteUser, long avatarId)
Return avatar using remote user permissions.
final SystemAndCustomAvatars getAvatars(ApplicationUser remoteUser, String owningObjectId)
Get avatars assigned to given subject - with permisions of remote user.
[Expand]
Inherited Methods
From class java.lang.Object
From interface com.atlassian.jira.avatar.TypeAvatarService

Public Constructors

public BasicTypedTypeAvatarService (Avatar.Type type, AvatarManager avatarManager, AvatarAccessPolicy policy)

Public Methods

public boolean canUserCreateAvatar (ApplicationUser remoteUser, String owningObjectId)

Return information if user can add avatar to given subject.

Parameters
remoteUser user whose permissions should be used
owningObjectId id of object (project/user/issuetype) to which this avatar is connected to

public Avatar createAvatar (ApplicationUser remoteUser, String owningObjectId, AvatarImageDataProvider imageDataProvider)

Adds new avatar to given subject with provided image data - with permissions of given remote user. Returns created avatar.

Parameters
remoteUser user whose permissions should be used
owningObjectId id of object (project/user/issuetype) to which this avatar will be connected to
imageDataProvider provider of image data for new avatar

public Avatar getAvatar (ApplicationUser remoteUser, long avatarId)

Return avatar using remote user permissions. May return null if user cannot access this avatar.

Parameters
remoteUser user whose permissions should be used
avatarId avatar id

public final SystemAndCustomAvatars getAvatars (ApplicationUser remoteUser, String owningObjectId)

Get avatars assigned to given subject - with permisions of remote user.

Parameters
remoteUser user whose permissions should be used
owningObjectId id of object (project/user/issuetype) to which this avatar is connected to
Returns
  • object with all system and accessible by user custom avatars