|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.liferay.faces.util.i18n.I18nWrapper
com.liferay.faces.util.i18n.I18nBundleBase
public abstract class I18nBundleBase
This is an abstract class that provides a convenient base implementation for introducing an internationalized ResourceBundle into the I18n delegation chain. For the sake of performance, lookups into the ResourceBundle
are cached by this class in a synchronized map.
| Constructor Summary | |
|---|---|
I18nBundleBase(I18n i18n)
|
|
| Method Summary | |
|---|---|
abstract String |
getBundleKey()
|
javax.faces.application.FacesMessage |
getFacesMessage(javax.faces.context.FacesContext facesContext,
Locale locale,
javax.faces.application.FacesMessage.Severity severity,
String messageId)
See I18n.getFacesMessage(FacesContext, Locale, FacesMessage.Severity, String) |
javax.faces.application.FacesMessage |
getFacesMessage(javax.faces.context.FacesContext facesContext,
Locale locale,
javax.faces.application.FacesMessage.Severity severity,
String messageId,
Object... arguments)
See I18n.getFacesMessage(FacesContext, Locale, FacesMessage.Severity, String, Object...) |
String |
getMessage(javax.faces.context.FacesContext facesContext,
Locale locale,
String messageId)
See I18n.getMessage(FacesContext, Locale, String) |
String |
getMessage(javax.faces.context.FacesContext facesContext,
Locale locale,
String messageId,
Object... arguments)
See I18n.getMessage(FacesContext, Locale, String, Object...) |
I18n |
getWrapped()
|
protected Cache<String,String> |
newConcurrentMessageCache(javax.faces.context.ExternalContext externalContext)
Returns a new message cache to be used by I18nBundleBase. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public I18nBundleBase(I18n i18n)
| Method Detail |
|---|
public abstract String getBundleKey()
public javax.faces.application.FacesMessage getFacesMessage(javax.faces.context.FacesContext facesContext,
Locale locale,
javax.faces.application.FacesMessage.Severity severity,
String messageId)
I18nWrapperI18n.getFacesMessage(FacesContext, Locale, FacesMessage.Severity, String)
getFacesMessage in interface I18ngetFacesMessage in class I18nWrapperfacesContext - The current faces context.locale - The locale of the message.severity - The severity of the message.messageId - The id of the message.
public javax.faces.application.FacesMessage getFacesMessage(javax.faces.context.FacesContext facesContext,
Locale locale,
javax.faces.application.FacesMessage.Severity severity,
String messageId,
Object... arguments)
I18nWrapperI18n.getFacesMessage(FacesContext, Locale, FacesMessage.Severity, String, Object...)
getFacesMessage in interface I18ngetFacesMessage in class I18nWrapperfacesContext - The current faces context.locale - The locale of the message.severity - The severity of the message.messageId - The id of the message.arguments - The values that are to be inserted according to the MessageFormat
pattern.
public String getMessage(javax.faces.context.FacesContext facesContext,
Locale locale,
String messageId)
I18nWrapperI18n.getMessage(FacesContext, Locale, String)
getMessage in interface I18ngetMessage in class I18nWrapperfacesContext - The current faces context.locale - The locale of the message.messageId - The id of the message.
public String getMessage(javax.faces.context.FacesContext facesContext,
Locale locale,
String messageId,
Object... arguments)
I18nWrapperI18n.getMessage(FacesContext, Locale, String, Object...)
getMessage in interface I18ngetMessage in class I18nWrapperfacesContext - The current faces context.locale - The locale of the message.messageId - The id of the message.arguments - The values that are to be inserted according to the MessageFormat
pattern.public I18n getWrapped()
getWrapped in interface javax.faces.FacesWrapper<I18n>getWrapped in class I18nWrapperprotected Cache<String,String> newConcurrentMessageCache(javax.faces.context.ExternalContext externalContext)
I18nBundleBase. The default implementation returns a Cache
instance obtained from CacheFactory.getConcurrentCacheInstance(javax.faces.context.ExternalContext, int)
(passing 16 as the initial cache capacity). The cache will be stored in the application map. This method is
called from the constructor of I18nBundleBase, so this method must not cause side effects and should not expect
I18nBundleBase (or its subclass) to be fully initialized.
externalContext - The external context associated with the current FacesContext.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||