Package org.h2.engine
Class SettingsBase
- java.lang.Object
-
- org.h2.engine.SettingsBase
-
- Direct Known Subclasses:
DbSettings
public class SettingsBase extends java.lang.ObjectThe base class for settings.
-
-
Field Summary
Fields Modifier and Type Field Description private java.util.HashMap<java.lang.String,java.lang.String>settings
-
Constructor Summary
Constructors Modifier Constructor Description protectedSettingsBase(java.util.HashMap<java.lang.String,java.lang.String> s)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected booleancontainsKey(java.lang.String k)Check if the settings contains the given key.protected booleanget(java.lang.String key, boolean defaultValue)Get the setting for the given key.protected intget(java.lang.String key, int defaultValue)Get the setting for the given key.protected java.lang.Stringget(java.lang.String key, java.lang.String defaultValue)Get the setting for the given key.java.util.HashMap<java.lang.String,java.lang.String>getSettings()Get all settings.java.util.Map.Entry<java.lang.String,java.lang.String>[]getSortedSettings()Get all settings in alphabetical order.(package private) voidset(java.lang.String key, boolean value)Set an entry in the key-value pair.
-
-
-
Method Detail
-
get
protected boolean get(java.lang.String key, boolean defaultValue)Get the setting for the given key.- Parameters:
key- the keydefaultValue- the default value- Returns:
- the setting
-
set
void set(java.lang.String key, boolean value)Set an entry in the key-value pair.- Parameters:
key- the keyvalue- the value
-
get
protected int get(java.lang.String key, int defaultValue)Get the setting for the given key.- Parameters:
key- the keydefaultValue- the default value- Returns:
- the setting
-
get
protected java.lang.String get(java.lang.String key, java.lang.String defaultValue)Get the setting for the given key.- Parameters:
key- the keydefaultValue- the default value- Returns:
- the setting
-
containsKey
protected boolean containsKey(java.lang.String k)
Check if the settings contains the given key.- Parameters:
k- the key- Returns:
- true if they do
-
getSettings
public java.util.HashMap<java.lang.String,java.lang.String> getSettings()
Get all settings.- Returns:
- the settings
-
getSortedSettings
public java.util.Map.Entry<java.lang.String,java.lang.String>[] getSortedSettings()
Get all settings in alphabetical order.- Returns:
- the settings
-
-