Modifier and Type | Field and Description |
---|---|
static Cascade |
EMPTY_CASCADE |
private static Pattern |
HEX_COLOR_PATTERN |
protected Map<String,Object> |
prop |
Constructor and Description |
---|
Cascade() |
Modifier and Type | Method and Description |
---|---|
Cascade |
clone() |
boolean |
containsKey(String key) |
static <T> T |
convertTo(Object o,
Class<T> klass) |
Object |
get(String key) |
<T> T |
get(String key,
T def,
Class<T> klass) |
<T> T |
get(String key,
T def,
Class<T> klass,
boolean suppressWarnings)
Get value for the given key
|
void |
put(String key,
Object val) |
void |
putOrClear(String key,
Object val) |
void |
remove(String key) |
private static Boolean |
toBool(Object o) |
private static Color |
toColor(Object o) |
private static Float |
toFloat(Object o) |
private static float[] |
toFloatArray(Object o) |
String |
toString() |
public static final Cascade EMPTY_CASCADE
private static final Pattern HEX_COLOR_PATTERN
public Cascade()
public <T> T get(String key, T def, Class<T> klass, boolean suppressWarnings)
T
- the expected typekey
- the keydef
- default value, can be nullklass
- the same as TsuppressWarnings
- show or don't show a warning when some value is
found, but cannot be converted to the requested typepublic void putOrClear(String key, Object val)
private static float[] toFloatArray(Object o)
public boolean containsKey(String key)