|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectwt.prefs.PrefsUtil
Description
The PrefsUtil class is a Utility class that provides String to Preference Node transformation
PreferenceHelper
Field Summary | |
private static Preferences |
root
The root preference |
Constructor Summary | |
PrefsUtil()
|
Method Summary | |
(package private) static String |
append(String nodeA,
String nodeB)
Appends nodeB to nodeA removing unnecessary separators Example: append("/foo", "bar") = "/foo/bar" Supported API: false |
static String |
createFullyQualifiedPreferenceName(String aNode,
String aKey)
Deprecated. |
static String |
createFullyQualifiedPreferenceName(String aParent,
String aNode,
String aKey)
Deprecated. |
static String |
get(String aNode,
String aKey,
String aDefault)
This method will get a preference from the Preferences Framework for the current user at the given node and key. |
static HashMap |
getNodeValues(Preferences pref)
Deprecated. |
(package private) static String |
node(String node)
Return the node name from an absolute path Example: node("/foo/bar") = "bar" Supported API: false |
(package private) static String |
node(String absNode,
String pathNode)
Return relative node given an absolute and path node Example: node("/foo/bar/node", "/foo") = "bar/node" Supported API: false |
(package private) static String |
parent(String node)
Return the String representing the parent of a Preference node. |
static String |
put(String aNode,
String aKey,
String aValue)
This method will insert a preference into the Preferences Framework for the current user at the given node and key. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
private static Preferences root
Constructor Detail |
public PrefsUtil()
Method Detail |
static String parent(String node)
node
- String representation of node for which parent is being
requestedstatic String node(String node)
node
- absolute String representation of nodestatic String node(String absNode, String pathNode)
absNode
- absolute String representation of nodepathNode
- return node relative to this pathstatic String append(String nodeA, String nodeB)
nodeA
- first partnodeB
- second partpublic static HashMap getNodeValues(Preferences pref)
Note: The contextMask should be set first using the
PrefsUtil.createContextMask( )
method to ensure that the
Preference node will be searched using the proper context.
Supported API: false
Replace With: wt.prefs.PreferenceHelper.getNodeValues()
pref
- The preference node.
public static String createFullyQualifiedPreferenceName(String aParent, String aNode, String aKey)
aParent
- The parent preferenceaNode
- The preference nodeaKey
- The preference key
public static final String createFullyQualifiedPreferenceName(String aNode, String aKey)
aNode
- The preference nodeaKey
- The preference key
public static final String get(String aNode, String aKey, String aDefault)
aNode
- The node to the preference (for example "/wt/doc" )aKey
- The key name of the preferenceaDefault
- The value to use as the default if there is no
preference
public static final String put(String aNode, String aKey, String aValue) throws WTException
aNode
- The node to the preference (for example "/wt/doc" )aKey
- The key name of the preferenceaValue
- The value to insert for the preference
WTException
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |