eu.webtoolkit.jwt
Class WXmlLocalizedStrings

java.lang.Object
  extended by eu.webtoolkit.jwt.WLocalizedStrings
      extended by eu.webtoolkit.jwt.WXmlLocalizedStrings

public class WXmlLocalizedStrings
extends WLocalizedStrings

WXmlLocalizedStrings is a WLocalizedStrings implementation which uses an XML file as input resource.


Constructor Summary
WXmlLocalizedStrings()
          Constructor.
 
Method Summary
 void refresh()
          Rereads the message resources.
 java.lang.String resolveKey(java.lang.String key)
          Resolves a key in the current locale.
 void use(java.lang.String bundleName)
          Use an XML file as input resource.
 void useBuiltin(java.lang.String bundle)
           
 
Methods inherited from class eu.webtoolkit.jwt.WLocalizedStrings
hibernate
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

WXmlLocalizedStrings

public WXmlLocalizedStrings()
Constructor.

Method Detail

use

public void use(java.lang.String bundleName)
Use an XML file as input resource.

Parameters:
bundleName -

refresh

public void refresh()
Description copied from class: WLocalizedStrings
Rereads the message resources.

Purge any cached key/values, if applicable.

The default implementation does nothing.

Overrides:
refresh in class WLocalizedStrings

resolveKey

public java.lang.String resolveKey(java.lang.String key)
Description copied from class: WLocalizedStrings
Resolves a key in the current locale.

This method is used by WString to obtain the UTF8 value corresponding to a key in the current locale.

Returns the value if the key could be resolved. Returns null otherwise.

Specified by:
resolveKey in class WLocalizedStrings
See Also:
WApplication.getLocale(), WString.tr(String key)

useBuiltin

public void useBuiltin(java.lang.String bundle)