Package org.openxava.util.impl
Class UserPreferences
- java.lang.Object
-
- java.util.prefs.Preferences
-
- java.util.prefs.AbstractPreferences
-
- org.openxava.util.impl.UserPreferences
-
public class UserPreferences extends java.util.prefs.AbstractPreferences
Implementation of Java Preferences for OX applications.It's not intended for use at global preferences for the JVM (that is as value for system property
java.util.prefs.PreferencesFactory
), but for obtaining it fromUsers.getCurrentPreferences()
.- Author:
- Javier Paniza
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
UserPreferences(java.util.prefs.AbstractPreferences parent, java.lang.String name, java.lang.String userName)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected java.lang.String[]
childrenNamesSpi()
protected java.util.prefs.AbstractPreferences
childSpi(java.lang.String name)
protected void
flushSpi()
static java.util.prefs.Preferences
getForUser(java.lang.String userName)
protected java.lang.String
getSpi(java.lang.String key)
protected java.lang.String[]
keysSpi()
protected void
putSpi(java.lang.String key, java.lang.String value)
static void
removeAll()
protected void
removeNodeSpi()
protected void
removeSpi(java.lang.String key)
protected void
syncSpi()
-
Methods inherited from class java.util.prefs.AbstractPreferences
absolutePath, addNodeChangeListener, addPreferenceChangeListener, cachedChildren, childrenNames, clear, exportNode, exportSubtree, flush, get, getBoolean, getByteArray, getChild, getDouble, getFloat, getInt, getLong, isRemoved, isUserNode, keys, name, node, nodeExists, parent, put, putBoolean, putByteArray, putDouble, putFloat, putInt, putLong, remove, removeNode, removeNodeChangeListener, removePreferenceChangeListener, sync, toString
-
-
-
-
Method Detail
-
getForUser
public static java.util.prefs.Preferences getForUser(java.lang.String userName) throws java.util.prefs.BackingStoreException
- Throws:
java.util.prefs.BackingStoreException
-
removeAll
public static void removeAll() throws java.util.prefs.BackingStoreException
- Throws:
java.util.prefs.BackingStoreException
- Since:
- 5.8
-
childSpi
protected java.util.prefs.AbstractPreferences childSpi(java.lang.String name)
- Specified by:
childSpi
in classjava.util.prefs.AbstractPreferences
-
childrenNamesSpi
protected java.lang.String[] childrenNamesSpi() throws java.util.prefs.BackingStoreException
- Specified by:
childrenNamesSpi
in classjava.util.prefs.AbstractPreferences
- Throws:
java.util.prefs.BackingStoreException
-
flushSpi
protected void flushSpi() throws java.util.prefs.BackingStoreException
- Specified by:
flushSpi
in classjava.util.prefs.AbstractPreferences
- Throws:
java.util.prefs.BackingStoreException
-
getSpi
protected java.lang.String getSpi(java.lang.String key)
- Specified by:
getSpi
in classjava.util.prefs.AbstractPreferences
-
keysSpi
protected java.lang.String[] keysSpi() throws java.util.prefs.BackingStoreException
- Specified by:
keysSpi
in classjava.util.prefs.AbstractPreferences
- Throws:
java.util.prefs.BackingStoreException
-
putSpi
protected void putSpi(java.lang.String key, java.lang.String value)
- Specified by:
putSpi
in classjava.util.prefs.AbstractPreferences
-
removeNodeSpi
protected void removeNodeSpi() throws java.util.prefs.BackingStoreException
- Specified by:
removeNodeSpi
in classjava.util.prefs.AbstractPreferences
- Throws:
java.util.prefs.BackingStoreException
-
removeSpi
protected void removeSpi(java.lang.String key)
- Specified by:
removeSpi
in classjava.util.prefs.AbstractPreferences
-
syncSpi
protected void syncSpi() throws java.util.prefs.BackingStoreException
- Specified by:
syncSpi
in classjava.util.prefs.AbstractPreferences
- Throws:
java.util.prefs.BackingStoreException
-
-