|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.ideo.sweetdevria.util.MessageResources
public abstract class MessageResources
Messages resources abstract class. Initially from org.apache.struts.util.MessageResourcesFactory.
| Field Summary | |
|---|---|
protected static MessageResourcesFactory |
defaultFactory
Default factory. |
protected MessageResourcesFactory |
factory
Factory. |
protected static org.apache.commons.logging.Log |
LOG
Logger. |
protected java.lang.String |
propertiesFileName
Properties file name. |
protected boolean |
returnNull
Return null ? |
| Constructor Summary | |
|---|---|
MessageResources(MessageResourcesFactory factory,
java.lang.String propertiesFileName)
Constructor. |
|
MessageResources(MessageResourcesFactory factory,
java.lang.String propertiesFileName,
boolean returnNull)
Constructor. |
|
| Method Summary | |
|---|---|
java.lang.String |
getConfig()
Get the config. |
MessageResourcesFactory |
getFactory()
Get the factory. |
abstract java.lang.String |
getMessage(java.util.Locale locale,
java.lang.String messageKey)
Get message from the specific locale. |
abstract java.lang.String |
getMessage(java.lang.String messageKey)
Get message from the default locale (English). |
abstract java.lang.String |
getMessage(java.lang.String key,
java.lang.Object object)
Get message by using object in argument. |
static MessageResources |
getMessageResources(java.lang.String propertiesFileName)
Get messages resources. |
boolean |
getReturnNull()
Get the returnNull. |
void |
setReturnNull(boolean returnNull)
Set the returnNull. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected static final org.apache.commons.logging.Log LOG
protected java.lang.String propertiesFileName
protected MessageResourcesFactory factory
protected boolean returnNull
protected static MessageResourcesFactory defaultFactory
| Constructor Detail |
|---|
public MessageResources(MessageResourcesFactory factory,
java.lang.String propertiesFileName)
factory - Factory used.propertiesFileName - Properties file name.
public MessageResources(MessageResourcesFactory factory,
java.lang.String propertiesFileName,
boolean returnNull)
factory - Factory used.propertiesFileName - Properties file name.returnNull - Return null ? (not used here)| Method Detail |
|---|
public abstract java.lang.String getMessage(java.util.Locale locale,
java.lang.String messageKey)
locale - locale in wich get message.messageKey - message key.
public abstract java.lang.String getMessage(java.lang.String messageKey)
messageKey - message key.
public abstract java.lang.String getMessage(java.lang.String key,
java.lang.Object object)
key - message key.object - Object used to get the locale (i.e. PageContext from where extract the locale).
public java.lang.String getConfig()
public MessageResourcesFactory getFactory()
public boolean getReturnNull()
public void setReturnNull(boolean returnNull)
returnNull - The returnNull to set.public static MessageResources getMessageResources(java.lang.String propertiesFileName)
propertiesFileName - Properties file name.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||