Class SharedDefaults
- All Implemented Interfaces:
Serializable
,Cloneable
,Map<String,
String>
Processes the shared default values. Updates and Persists new key - value (default) pair
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class java.util.AbstractMap
AbstractMap.SimpleEntry<K extends Object,
V extends Object>, AbstractMap.SimpleImmutableEntry<K extends Object, V extends Object> -
Field Summary
-
Constructor Summary
ConstructorDescriptionDefault Constructor for creating and instantiating objects. -
Method Summary
Modifier and TypeMethodDescriptionvoid
addToBackEndStorage
(String name, String value) Adds data to the backend XML (persistence) Data obtained from the PreferencePage GUI.void
deleteBackEndStorage
(String[] deleteName) Deletes the key-value pair from the backend with Key as identifier.static SharedDefaults
This method returns the latest key value pair (HashMap)void
This method persists the latest data (HashMap) in the XML file New data obtained from the PreferencePage GUI.void
updateShareDefaultsMap
(Map<String, String> sharedMap) This method updates the HashMap with new key-value pair into the XML filevoid
updateToBackEndStorage
(String updateName, String updateValue) Updates backend with changed value for a specific key(name)Methods inherited from class java.util.HashMap
clear, clone, compute, computeIfAbsent, computeIfPresent, containsKey, containsValue, entrySet, forEach, get, getOrDefault, isEmpty, keySet, merge, put, putAll, putIfAbsent, remove, remove, replace, replace, replaceAll, size, values
Methods inherited from class java.util.AbstractMap
equals, hashCode, toString
-
Field Details
-
document
-
SET
Static reference string for getting (GET) and storing (SET) shareddefaults.xml- See Also:
-
GET
- See Also:
-
ResourceFolder
Specifies the folder name present in the plugin- See Also:
-
-
Constructor Details
-
SharedDefaults
public SharedDefaults()Default Constructor for creating and instantiating objects. On the startup of Template Engine, if it checks for the existence of TempSharedDefaultsXML file, then it is determined that the last Template Engine process under went some System destructive events and takes up reconstructive process to regain the consistent data by persisting all information first into temporary file and then into actual file.
-
-
Method Details
-
getInstance
- Returns:
- the shared SharedDefaults Instance
-
addToBackEndStorage
Adds data to the backend XML (persistence) Data obtained from the PreferencePage GUI. -
updateToBackEndStorage
Updates backend with changed value for a specific key(name)- Parameters:
updateName
-updateValue
-
-
deleteBackEndStorage
Deletes the key-value pair from the backend with Key as identifier.- Parameters:
deleteName
-
-