public class DatabaseMessageProvider extends Object implements MessageProvider
MessageProvider
that stores messages in a databaseConstructor and Description |
---|
DatabaseMessageProvider() |
Modifier and Type | Method and Description |
---|---|
Collection<Message> |
getAllMessagesForComponent(String namespace,
String component,
String locale)
Gets all message objects for the given namespace, component, and locale
|
LookupService |
getLookupService() |
Message |
getMessage(String namespace,
String component,
String key,
String locale)
Gets the
Message object that has the given namespace, component, key, and locale |
protected Collection<Message> |
getMessageByCriteria(String namespace,
String component,
String key,
String locale)
Performs a query using the
LookupService to retrieve messages that match the given
namespace, component, name, and locale. |
void |
setLookupService(LookupService lookupService) |
public DatabaseMessageProvider()
public Message getMessage(String namespace, String component, String key, String locale)
MessageProvider
Message
object that has the given namespace, component, key, and localegetMessage
in interface MessageProvider
namespace
- namespace code the message belongs tocomponent
- component code the namespace is associated withkey
- key that identifies the message within the namespace and componentlocale
- locale code for the message to returnMessageProvider.getMessage(java.lang.String, java.lang.String,
java.lang.String, java.lang.String)
public Collection<Message> getAllMessagesForComponent(String namespace, String component, String locale)
MessageProvider
getAllMessagesForComponent
in interface MessageProvider
namespace
- namespace code the message belongs tocomponent
- component code the namespace is associated withlocale
- locale code for the message to returnMessageProvider.getAllMessagesForComponent(java.lang.String,
java.lang.String, java.lang.String)
protected Collection<Message> getMessageByCriteria(String namespace, String component, String key, String locale)
LookupService
to retrieve messages that match the given
namespace, component, name, and locale. Not parameters maybe empty in which case they will not be added
to the criterianamespace
- namespace code to search forcomponent
- component code to search forkey
- key of the parameter to findlocale
- locale code to search forpublic LookupService getLookupService()
public void setLookupService(LookupService lookupService)
Copyright © 2005–2016 The Kuali Foundation. All rights reserved.