com.atlassian.jira.plugin.myjirahome
Class MyJiraHomeLinkerImpl

java.lang.Object
  extended by com.atlassian.jira.plugin.myjirahome.MyJiraHomeLinkerImpl
All Implemented Interfaces:
MyJiraHomeLinker

public class MyJiraHomeLinkerImpl
extends Object
implements MyJiraHomeLinker

Resolves the current My JIRA Home location by looking up the plugin and returning the rendered url. If the plugin is not enabled, the MyJiraHomeLinker.DEFAULT_HOME_NOT_ANON is returned for logged in users, or MyJiraHomeLinker.DEFAULT_HOME_ANON for anons.

Since:
5.1

Field Summary
 
Fields inherited from interface com.atlassian.jira.plugin.myjirahome.MyJiraHomeLinker
DEFAULT_HOME_ANON, DEFAULT_HOME_NOT_ANON
 
Constructor Summary
MyJiraHomeLinkerImpl(com.atlassian.plugin.PluginAccessor pluginAccessor, MyJiraHomePreference myJiraHomePreference, ProjectService projectService)
           
 
Method Summary
 String getHomeLink(com.atlassian.crowd.embedded.api.User user)
          Returns the My JIRA Home as a link for the given user.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MyJiraHomeLinkerImpl

public MyJiraHomeLinkerImpl(@Nonnull
                            com.atlassian.plugin.PluginAccessor pluginAccessor,
                            @Nonnull
                            MyJiraHomePreference myJiraHomePreference,
                            ProjectService projectService)
Method Detail

getHomeLink

@Nonnull
public String getHomeLink(@Nullable
                                  com.atlassian.crowd.embedded.api.User user)
Description copied from interface: MyJiraHomeLinker
Returns the My JIRA Home as a link for the given user.

Specified by:
getHomeLink in interface MyJiraHomeLinker
Parameters:
user - the user for which the home link is requested
Returns:
the user's My JIRA Home, or one of MyJiraHomeLinker.DEFAULT_HOME_ANON if anonymous or MyJiraHomeLinker.DEFAULT_HOME_NOT_ANON if logged in if none is defined or there were errors while loading.


Copyright © 2002-2013 Atlassian. All Rights Reserved.