Package com.helger.xml.resourcebundle
Class XMLResourceBundle
- java.lang.Object
-
- java.util.ResourceBundle
-
- com.helger.xml.resourcebundle.XMLResourceBundle
-
@Immutable public final class XMLResourceBundle extends ResourceBundle
Helper class to handle XML based properties. It is read-only.
See Resource.Control Javadocs- Author:
- Philip Helger
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class java.util.ResourceBundle
ResourceBundle.Control
-
-
Field Summary
-
Fields inherited from class java.util.ResourceBundle
parent
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description com.helger.commons.collection.impl.ICommonsMap<String,String>getAllValues()static IMicroDocumentgetAsPropertiesXML(com.helger.commons.collection.impl.ICommonsMap<String,String> aMap)Enumeration<String>getKeys()static XMLResourceBundlegetXMLBundle(String sBaseName)static XMLResourceBundlegetXMLBundle(String sBaseName, Locale aLocale)static XMLResourceBundlegetXMLBundle(String sBaseName, Locale aLocale, ClassLoader aClassLoader)protected StringhandleGetObject(String sKey)Main internal lookupprotected Set<String>handleKeySet()More efficient version to retrieve the keySetstatic com.helger.commons.collection.impl.ICommonsOrderedMap<String,String>readFromPropertiesXML(InputStream aIS)-
Methods inherited from class java.util.ResourceBundle
clearCache, clearCache, containsKey, getBaseBundleName, getBundle, getBundle, getBundle, getBundle, getBundle, getBundle, getBundle, getBundle, getLocale, getObject, getString, getStringArray, keySet, setParent
-
-
-
-
Method Detail
-
readFromPropertiesXML
@Nonnull @ReturnsMutableCopy public static com.helger.commons.collection.impl.ICommonsOrderedMap<String,String> readFromPropertiesXML(@Nonnull @WillClose InputStream aIS)
-
getAsPropertiesXML
@Nonnull public static IMicroDocument getAsPropertiesXML(@Nonnull com.helger.commons.collection.impl.ICommonsMap<String,String> aMap)
-
getAllValues
@Nonnull @ReturnsMutableCopy public com.helger.commons.collection.impl.ICommonsMap<String,String> getAllValues()
-
handleKeySet
@CodingStyleguideUnaware protected Set<String> handleKeySet()
More efficient version to retrieve the keySet- Overrides:
handleKeySetin classResourceBundle- Returns:
- all resource names
-
handleGetObject
protected String handleGetObject(@Nullable String sKey)
Main internal lookup- Specified by:
handleGetObjectin classResourceBundle- Returns:
- the string matching the passed key
-
getKeys
public Enumeration<String> getKeys()
- Specified by:
getKeysin classResourceBundle
-
getXMLBundle
@Nonnull public static XMLResourceBundle getXMLBundle(@Nonnull String sBaseName)
-
getXMLBundle
@Nonnull public static XMLResourceBundle getXMLBundle(@Nonnull String sBaseName, @Nonnull Locale aLocale)
-
getXMLBundle
@Nonnull public static XMLResourceBundle getXMLBundle(@Nonnull String sBaseName, @Nonnull Locale aLocale, @Nonnull ClassLoader aClassLoader)
-
-