public class MessageSource extends GroovyObjectSupport
ResourceBundle
 instances for simple i18n support.| Constructor and Description | 
|---|
| MessageSource(java.lang.Class type) | 
| MessageSource(java.lang.Class[] types) | 
| MessageSource(java.lang.String name) | 
| MessageSource(java.lang.String[] names) | 
| Modifier and Type | Method and Description | 
|---|---|
| java.lang.String | format(java.lang.String code,
      java.lang.Object[] args)Format a message (based on  MessageFormatusing the message
 from the resource bundles using the given code as a pattern and the
 given objects as arguments. | 
| java.lang.String | getMessage(java.lang.String code)Get a raw message from the resource bundles using the given code. | 
| java.lang.Object | getProperty(java.lang.String name)Retrieves a property value. | 
getMetaClass, invokeMethod, setMetaClass, setPropertypublic MessageSource(java.lang.String[] names)
public MessageSource(java.lang.String name)
public MessageSource(java.lang.Class[] types)
public MessageSource(java.lang.Class type)
public java.lang.String getMessage(java.lang.String code)
public java.lang.String format(java.lang.String code,
                               java.lang.Object[] args)
MessageFormat using the message
 from the resource bundles using the given code as a pattern and the
 given objects as arguments.public java.lang.Object getProperty(java.lang.String name)
GroovyObjectgetProperty in interface GroovyObjectgetProperty in class GroovyObjectSupportname - the name of the property of interestgetMessage(String)