com.atlassian.jira.user
Class MockUserLocaleStore

java.lang.Object
  extended by com.atlassian.jira.user.MockUserLocaleStore
All Implemented Interfaces:
UserLocaleStore

public class MockUserLocaleStore
extends Object
implements UserLocaleStore

Since:
v6.2.3

Constructor Summary
MockUserLocaleStore()
           
MockUserLocaleStore(Locale defaultLocale)
           
 
Method Summary
 Locale getDefaultLocale()
          Return the Locale to use for a user without a locale.
 Locale getLocale(ApplicationUser user)
          Return the Locale associated with the passed user.
 Locale getLocale(com.atlassian.crowd.embedded.api.User user)
          Return the Locale associated with the passed user.
 MockUserLocaleStore setLocale(Principal user, Locale locale)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MockUserLocaleStore

public MockUserLocaleStore()

MockUserLocaleStore

public MockUserLocaleStore(Locale defaultLocale)
Method Detail

getLocale

@Nonnull
public Locale getLocale(ApplicationUser user)
Description copied from interface: UserLocaleStore
Return the Locale associated with the passed user.

Specified by:
getLocale in interface UserLocaleStore
Parameters:
user - the user for the query.
Returns:
the Locale associated with the passed user.

getLocale

@Nonnull
public Locale getLocale(com.atlassian.crowd.embedded.api.User user)
Description copied from interface: UserLocaleStore
Return the Locale associated with the passed user.

Specified by:
getLocale in interface UserLocaleStore
Parameters:
user - the user for the query.
Returns:
the Locale associated with the passed user.

setLocale

public MockUserLocaleStore setLocale(Principal user,
                                     Locale locale)

getDefaultLocale

@Nonnull
public Locale getDefaultLocale()
Description copied from interface: UserLocaleStore
Return the Locale to use for a user without a locale.

Specified by:
getDefaultLocale in interface UserLocaleStore
Returns:
the default locale of JIRA.


Copyright © 2002-2014 Atlassian. All Rights Reserved.