org.trails.i18n
Class HiveMindMessageSource

java.lang.Object
  extended by org.trails.i18n.AbstractMessageSource
      extended by org.trails.i18n.HiveMindMessageSource
All Implemented Interfaces:
TrailsMessageSource

public class HiveMindMessageSource
extends AbstractMessageSource


Field Summary
 
Fields inherited from interface org.trails.i18n.TrailsMessageSource
EMPTY_ARGUMENTS
 
Constructor Summary
HiveMindMessageSource()
           
 
Method Summary
 java.lang.String getMessage(java.lang.String key)
          Return a internationalized message.
 java.lang.String getMessage(java.lang.String key, java.util.Locale locale)
          Return a internationalized message.
 java.lang.String getMessage(java.lang.String key, java.lang.Object[] args)
          Return a internationalized message specifing arguments to format this message.
 java.lang.String getMessage(java.lang.String key, java.lang.Object[] args, java.util.Locale locale)
          Return a internationalized message specifing arguments to format this message.
 void setMessageSource(org.apache.hivemind.Messages messageSource)
           
 void setThreadLocale(org.apache.hivemind.service.ThreadLocale threadLocale)
           
 
Methods inherited from class org.trails.i18n.AbstractMessageSource
getDisplayName, getMessageWithDefaultValue, getMessageWithDefaultValue, getMessageWithDefaultValue, getMessageWithDefaultValue, getPluralDislayName
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

HiveMindMessageSource

public HiveMindMessageSource()
Method Detail

getMessage

public java.lang.String getMessage(java.lang.String key)
Description copied from interface: TrailsMessageSource
Return a internationalized message.

Parameters:
key - Key used to locate the message.
Returns:
Localized message. Return null if message not found.

getMessage

public java.lang.String getMessage(java.lang.String key,
                                   java.lang.Object[] args)
Description copied from interface: TrailsMessageSource
Return a internationalized message specifing arguments to format this message.

Parameters:
key - Key used to locate the message.
args - Arguments to format the message.
Returns:
Localized message. Return null of message not found.

getMessage

public java.lang.String getMessage(java.lang.String key,
                                   java.util.Locale locale)
Description copied from interface: TrailsMessageSource
Return a internationalized message.

Sometimes it makes sense to force a Locale, but don't overuse this method.

Parameters:
key - Key used to locate the message.
locale - Locale used to locate message.
Returns:
Localized message. Return null if message not found.

getMessage

public java.lang.String getMessage(java.lang.String key,
                                   java.lang.Object[] args,
                                   java.util.Locale locale)
Description copied from interface: TrailsMessageSource
Return a internationalized message specifing arguments to format this message.

Sometimes it makes sense to force a Locale, but don't overuse this method.

Parameters:
key - Key used to locate the message.
args - Arguments to format the message.
locale - Locale used to locate message.
Returns:
Localized message. Return null of message not found.

setThreadLocale

public void setThreadLocale(org.apache.hivemind.service.ThreadLocale threadLocale)

setMessageSource

public void setMessageSource(org.apache.hivemind.Messages messageSource)


Copyright © 2004-2008. All Rights Reserved.