public class CachedXliffResourceBundleWrapper extends XliffResourceBundleWrapper
ResourceBundleWrapperRT.DefaultSearchContext, ResourceBundleWrapperRT.SearchType
ResourceBundleWrapper.KeyInfo
_parent
Constructor and Description |
---|
CachedXliffResourceBundleWrapper() |
Modifier and Type | Method and Description |
---|---|
boolean |
addEntry(java.lang.String key, java.lang.String text, java.util.Map<java.lang.String,java.lang.String> metadata)
Adds a new entry (key, value, and optional metadata) into the resource bundle.
|
boolean |
deleteEntry(java.lang.String key)
Deletes the resource bundle entry identified by
key . |
protected java.util.Map<java.lang.String,ResourceBundleWrapper.KeyInfo> |
getBaseKeyMap() |
protected java.util.Map<java.lang.String,java.lang.String> |
getBaseKeyValueMap() |
protected org.w3c.dom.Document |
getDocument() |
void |
parse(org.w3c.dom.Document document) |
void |
parse(java.net.URL url) |
void |
setDocument(org.w3c.dom.Document document)
This should only be used when dealing with an override bundle and via the AppBundleInfoRT class
|
boolean |
updateEntry(java.lang.String key, java.lang.String text, java.util.Map<java.lang.String,java.lang.String> metadata)
Updates the specified key to have the specified text and metadata.
|
addEntryNoDialog, getKeyValueMap, getMetadata, getMetadataObject, getMetadataObject, getMOKey, getString, keySet, parse, setParent, setWritable, updateDocument, updateEntryNoDialog
addEntry, addResourceBundleListener, findKeys, findKeys, findKeysByMetaData, findKeysByMetaData, findKeysByText, findKeysByText, findKeysLikeKey, findKeysLikeKey, findKeysLikeMetaData, findKeysLikeText, findKeysLikeText, getBundleId, getChainedKeyValueMap, getKeyGenerator, getMetadataFromParentChain, getParent, getParentChain, getParentList, refreshBundleIfNeeded, removeResourceBundleListener, setBundleId, setKeyGenerator, setParentList, setURL, toString
public boolean addEntry(java.lang.String key, java.lang.String text, java.util.Map<java.lang.String,java.lang.String> metadata)
ResourceBundleWrapper
addEntry
in interface ResourceBundleWrapper
addEntry
in class XliffResourceBundleWrapper
key
- The key name to use in the resource bundle.text
- The text to be translated.metadata
- Any associated metadata about the translation string This parameter may be null
true
on successpublic boolean updateEntry(java.lang.String key, java.lang.String text, java.util.Map<java.lang.String,java.lang.String> metadata)
ResourceBundleWrapper
updateEntry
in interface ResourceBundleWrapper
updateEntry
in class XliffResourceBundleWrapper
key
- The key to updatetext
- The new text for the given keymetadata
- Any metadata to change. Existing metadata is merged with the new metadata, unless there is a key with a null value, then the existing metadata for that key is removed. If metadata
is null
then the existing metadata will be unchanged.true
on successpublic boolean deleteEntry(java.lang.String key)
ResourceBundleWrapper
key
. If key
does not exist, then a value of false
is returned.deleteEntry
in interface ResourceBundleWrapper
deleteEntry
in class XliffResourceBundleWrapper
key
- The key to deletetrue
If the key is found and deleted success.protected java.util.Map<java.lang.String,ResourceBundleWrapper.KeyInfo> getBaseKeyMap()
getBaseKeyMap
in class XliffResourceBundleWrapper
protected java.util.Map<java.lang.String,java.lang.String> getBaseKeyValueMap()
getBaseKeyValueMap
in class XliffResourceBundleWrapper
public void setDocument(org.w3c.dom.Document document)
XliffResourceBundleWrapper
setDocument
in class XliffResourceBundleWrapper
protected org.w3c.dom.Document getDocument()
getDocument
in class XliffResourceBundleWrapper
public void parse(org.w3c.dom.Document document)
parse
in class XliffResourceBundleWrapper
public void parse(java.net.URL url)
parse
in class XliffResourceBundleWrapper