org.browsecode.helpers.preferences
Class PreferencesSubset
java.lang.Object
org.browsecode.helpers.preferences.PreferencesSubset
- All Implemented Interfaces:
- HasKeyValues, HasKeyValuesModifiable, KeyValuesModifiable, Preferences
public class PreferencesSubset
- extends java.lang.Object
- implements Preferences
Method Summary |
java.lang.Boolean |
getBooleanObjectPreference(java.lang.String key)
|
boolean |
getBooleanPreference(java.lang.String key)
Returns false if the value isn't in the database, by default. |
boolean |
getBooleanPreference(java.lang.String key,
boolean defaultValue)
Returns false if the value isn't in the database, by default. |
java.util.Vector<java.lang.Boolean> |
getBooleanPreferenceVector(java.lang.String key)
|
java.lang.Integer |
getIntegerPreference(java.lang.String key)
|
int |
getIntPreference(java.lang.String key)
Returns -1 if the value isn't in the database. |
java.lang.String |
getPreference(java.lang.String key)
|
java.lang.String[] |
getPreferenceList(java.lang.String key)
|
Preferences |
getPreferencesSubset(java.lang.String key)
|
Preferences |
getPreferencesSubsetFromVector(java.lang.String key,
int vectorIndex)
|
Preferences |
getPreferencesSubsetFromVectorName(java.lang.String nameInVector)
|
Preferences |
getPreferencesSubsetFromVectorName(java.lang.String key,
java.lang.String nameInVector)
|
java.util.Vector<java.lang.String> |
getPreferenceVector(java.lang.String key)
|
java.util.Vector<java.util.Vector<java.lang.String>> |
getPreferenceVectorOfVectors(java.lang.String key)
|
java.lang.String |
getValue(java.lang.String key)
|
void |
removePreferenceVectorIndex(java.lang.String key,
int indexToDelete)
|
void |
savePrefs()
|
void |
setBooleanObjectPreference(java.lang.String key,
java.lang.Boolean value)
|
void |
setBooleanPreference(java.lang.String key,
boolean value)
|
void |
setBooleanPreferenceVector(java.lang.String key,
java.util.Vector<java.lang.Boolean> v)
|
void |
setIntegerPreference(java.lang.String key,
java.lang.Integer value)
|
void |
setIntPreference(java.lang.String key,
int value)
|
void |
setPreference(java.lang.String key,
java.lang.String value)
|
void |
setPreferenceList(java.lang.String key,
java.lang.String[] values)
|
void |
setPreferenceVector(java.lang.String key,
java.util.Vector<java.lang.String> v)
|
void |
setPreferenceVectorOfVectors(java.lang.String key,
java.util.Vector<java.util.Vector<java.lang.String>> v)
|
void |
setValue(java.lang.String key,
java.lang.String value)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
savePrefs
public void savePrefs()
- Specified by:
savePrefs
in interface Preferences
getPreferenceList
public java.lang.String[] getPreferenceList(java.lang.String key)
- Specified by:
getPreferenceList
in interface Preferences
setPreferenceVector
public void setPreferenceVector(java.lang.String key,
java.util.Vector<java.lang.String> v)
- Specified by:
setPreferenceVector
in interface Preferences
setBooleanPreferenceVector
public void setBooleanPreferenceVector(java.lang.String key,
java.util.Vector<java.lang.Boolean> v)
- Specified by:
setBooleanPreferenceVector
in interface Preferences
removePreferenceVectorIndex
public void removePreferenceVectorIndex(java.lang.String key,
int indexToDelete)
- Specified by:
removePreferenceVectorIndex
in interface Preferences
setPreferenceVectorOfVectors
public void setPreferenceVectorOfVectors(java.lang.String key,
java.util.Vector<java.util.Vector<java.lang.String>> v)
- Specified by:
setPreferenceVectorOfVectors
in interface Preferences
getPreferenceVector
public java.util.Vector<java.lang.String> getPreferenceVector(java.lang.String key)
- Specified by:
getPreferenceVector
in interface Preferences
getBooleanPreferenceVector
public java.util.Vector<java.lang.Boolean> getBooleanPreferenceVector(java.lang.String key)
- Specified by:
getBooleanPreferenceVector
in interface Preferences
getPreferenceVectorOfVectors
public java.util.Vector<java.util.Vector<java.lang.String>> getPreferenceVectorOfVectors(java.lang.String key)
- Specified by:
getPreferenceVectorOfVectors
in interface Preferences
getIntPreference
public int getIntPreference(java.lang.String key)
- Description copied from interface:
Preferences
- Returns -1 if the value isn't in the database.
- Specified by:
getIntPreference
in interface Preferences
- Returns:
getIntegerPreference
public java.lang.Integer getIntegerPreference(java.lang.String key)
- Specified by:
getIntegerPreference
in interface Preferences
getBooleanPreference
public boolean getBooleanPreference(java.lang.String key)
- Description copied from interface:
Preferences
- Returns false if the value isn't in the database, by default.
- Specified by:
getBooleanPreference
in interface Preferences
- Returns:
getBooleanPreference
public boolean getBooleanPreference(java.lang.String key,
boolean defaultValue)
- Description copied from interface:
Preferences
- Returns false if the value isn't in the database, by default.
- Specified by:
getBooleanPreference
in interface Preferences
- Returns:
getBooleanObjectPreference
public java.lang.Boolean getBooleanObjectPreference(java.lang.String key)
- Specified by:
getBooleanObjectPreference
in interface Preferences
getPreference
public java.lang.String getPreference(java.lang.String key)
- Specified by:
getPreference
in interface Preferences
setPreference
public void setPreference(java.lang.String key,
java.lang.String value)
- Specified by:
setPreference
in interface Preferences
setIntPreference
public void setIntPreference(java.lang.String key,
int value)
- Specified by:
setIntPreference
in interface Preferences
setIntegerPreference
public void setIntegerPreference(java.lang.String key,
java.lang.Integer value)
- Specified by:
setIntegerPreference
in interface Preferences
setBooleanPreference
public void setBooleanPreference(java.lang.String key,
boolean value)
- Specified by:
setBooleanPreference
in interface Preferences
setBooleanObjectPreference
public void setBooleanObjectPreference(java.lang.String key,
java.lang.Boolean value)
- Specified by:
setBooleanObjectPreference
in interface Preferences
setPreferenceList
public void setPreferenceList(java.lang.String key,
java.lang.String[] values)
- Specified by:
setPreferenceList
in interface Preferences
getPreferencesSubset
public Preferences getPreferencesSubset(java.lang.String key)
- Specified by:
getPreferencesSubset
in interface Preferences
getPreferencesSubsetFromVector
public Preferences getPreferencesSubsetFromVector(java.lang.String key,
int vectorIndex)
- Specified by:
getPreferencesSubsetFromVector
in interface Preferences
getPreferencesSubsetFromVectorName
public Preferences getPreferencesSubsetFromVectorName(java.lang.String nameInVector)
- Specified by:
getPreferencesSubsetFromVectorName
in interface Preferences
getPreferencesSubsetFromVectorName
public Preferences getPreferencesSubsetFromVectorName(java.lang.String key,
java.lang.String nameInVector)
- Specified by:
getPreferencesSubsetFromVectorName
in interface Preferences
setValue
public void setValue(java.lang.String key,
java.lang.String value)
- Specified by:
setValue
in interface KeyValuesModifiable
getValue
public java.lang.String getValue(java.lang.String key)
- Specified by:
getValue
in interface HasKeyValues