org.utgenome.gwt.utgb.client.util
Class CanonicalProperties
java.lang.Object
java.util.AbstractMap<K,V>
java.util.HashMap<String,String>
org.utgenome.gwt.utgb.client.util.CanonicalProperties
- All Implemented Interfaces:
- Serializable, Cloneable, Map<String,String>
public class CanonicalProperties
- extends HashMap<String,String>
Using canonical parameter keys for providing case and space insensitive property map.
- Author:
- leo
- See Also:
- Serialized Form
Method Summary |
void |
add(String key,
boolean value)
|
void |
add(String key,
float value)
|
void |
add(String key,
int value)
|
void |
add(String key,
long value)
|
void |
add(String key,
String value)
|
String |
get(String key)
|
String |
get(String key,
String defaultValue)
Gets the String value associated with the given key. |
boolean |
getBoolean(String key)
|
boolean |
getBoolean(String key,
boolean defaultValue)
Gets the boolean value associated with the given key. |
float |
getFloat(String key)
|
float |
getFloat(String key,
float defaultValue)
Gets the float value associated with the given key. |
int |
getInt(String key)
|
int |
getInt(String key,
int defaultValue)
Gets the integer value associated with the given key. |
String |
put(String key,
String value)
|
void |
putAll(Map<? extends String,? extends String> m)
|
static String |
toCanonicalName(String key)
|
static String |
toNaturalName(String keyName)
|
Methods inherited from class java.util.HashMap |
clear, clone, containsKey, containsValue, entrySet, get, isEmpty, keySet, remove, size, values |
CanonicalProperties
public CanonicalProperties()
toCanonicalName
public static String toCanonicalName(String key)
toNaturalName
public static String toNaturalName(String keyName)
putAll
public void putAll(Map<? extends String,? extends String> m)
- Specified by:
putAll
in interface Map<String,String>
- Overrides:
putAll
in class HashMap<String,String>
put
public String put(String key,
String value)
- Specified by:
put
in interface Map<String,String>
- Overrides:
put
in class HashMap<String,String>
add
public void add(String key,
String value)
add
public void add(String key,
int value)
add
public void add(String key,
long value)
add
public void add(String key,
float value)
add
public void add(String key,
boolean value)
get
public String get(String key)
get
public String get(String key,
String defaultValue)
- Gets the String value associated with the given key. If any corresponding value is not found, returns the default
value.
- Parameters:
key
- the keydefaultValue
- the default value
- Returns:
- the string value
getInt
public int getInt(String key)
getInt
public int getInt(String key,
int defaultValue)
- Gets the integer value associated with the given key. If any corresponding value is not found, returns the given
default value
- Parameters:
key
- defaultValue
-
- Returns:
getFloat
public float getFloat(String key)
getFloat
public float getFloat(String key,
float defaultValue)
- Gets the float value associated with the given key. If any corresponding value is not found, returns the given
default value
- Parameters:
key
- defaultValue
-
- Returns:
getBoolean
public boolean getBoolean(String key)
getBoolean
public boolean getBoolean(String key,
boolean defaultValue)
- Gets the boolean value associated with the given key. If any corresponding value is not found, returns the given
default value
- Parameters:
key
- defaultValue
-
- Returns:
Copyright © 2007-2012 utgenome.org. All Rights Reserved.