com.atlassian.jira.avatar
Interface AvatarImageResolver

All Known Implementing Classes:
BasicAvatarsImageResolver, IssueTypeAvatarImageResolver, ProjectAvatarImageResolver

@ExperimentalApi
public interface AvatarImageResolver

Provides links (or image date) to display avatar image in given size.

Since:
v6.3
See Also:
UniversalAvatarsService.getImages(com.atlassian.jira.avatar.Avatar.Type)

Method Summary
 URI getAvatarAbsoluteUri(ApplicationUser remoteUser, Avatar avatar, Avatar.Size requestedSize)
          Return absolute link to display avatar image of given size.
 URI getAvatarRelativeUri(ApplicationUser remoteUser, Avatar avatar, Avatar.Size requestedSize)
          Return link (relative to application context) to display avatar image of given size.
 

Method Detail

getAvatarAbsoluteUri

@Nonnull
URI getAvatarAbsoluteUri(@Nullable
                                 ApplicationUser remoteUser,
                                 @Nonnull
                                 Avatar avatar,
                                 @Nullable
                                 Avatar.Size requestedSize)
Return absolute link to display avatar image of given size.

Parameters:
remoteUser - user that access avatar - null can be used for anonymous access.
avatar - avatar where to look for images
requestedSize - requested size or null if default size should be used.
Returns:
absolute url

getAvatarRelativeUri

@Nonnull
URI getAvatarRelativeUri(@Nullable
                                 ApplicationUser remoteUser,
                                 @Nonnull
                                 Avatar avatar,
                                 @Nullable
                                 Avatar.Size requestedSize)
Return link (relative to application context) to display avatar image of given size.

Parameters:
remoteUser - user that access avatar - null can be used for anonymous access.
avatar - avatar where to look for images
requestedSize - requested size or null if default size should be used.
Returns:
the relative uri to the avatar with the requested size, relative to servletContext.


Copyright © 2002-2015 Atlassian. All Rights Reserved.