public class Value extends Object implements Cloneable
| Constructor and Description |
|---|
Value()
Construct a new null Value.
|
Value(Boolean value) |
Value(Double value) |
Value(Instant value) |
Value(Integer value) |
Value(List<Value> value) |
Value(Object value)
Construct a new Value with an Object.
|
Value(String value) |
Value(Structure value) |
Value(Value value) |
| Modifier and Type | Method and Description |
|---|---|
Boolean |
asBoolean()
Retrieve the underlying Boolean value, or null.
|
Double |
asDouble()
Retrieve the underlying numeric value as a Double, or null.
|
Instant |
asInstant()
Retrieve the underlying Instant value, or null.
|
Integer |
asInteger()
Retrieve the underlying numeric value as an Integer, or null.
|
List<Value> |
asList()
Retrieve the underlying List value, or null.
|
Object |
asObject()
Retrieve the underlying object.
|
String |
asString()
Retrieve the underlying String value, or null.
|
Structure |
asStructure()
Retrieve the underlying Structure value, or null.
|
protected Value |
clone()
Perform deep clone of value object.
|
protected void |
finalize() |
boolean |
isBoolean()
Check if this Value represents a Boolean.
|
boolean |
isInstant()
Check if this Value represents an Instant.
|
boolean |
isList()
Check if this Value represents a List of Values.
|
boolean |
isNull()
Check if this Value represents null.
|
boolean |
isNumber()
Check if this Value represents a numeric value.
|
boolean |
isString()
Check if this Value represents a String.
|
boolean |
isStructure()
Check if this Value represents a Structure.
|
static Value |
objectToValue(Object object)
Wrap an object into a Value.
|
public Value()
public Value(Object value) throws InstantiationException
value - to be wrapped.InstantiationException - if value is not a valid type
(boolean, string, int, double, list, structure, instant)public Value(Value value)
public Value(Boolean value)
public Value(String value)
public Value(Integer value)
public Value(Double value)
public Value(Structure value)
public Value(Instant value)
public boolean isNull()
public boolean isBoolean()
public boolean isString()
public boolean isNumber()
public boolean isStructure()
public boolean isList()
public boolean isInstant()
public Boolean asBoolean()
public Object asObject()
public String asString()
public Integer asInteger()
public Double asDouble()
public Structure asStructure()
public Instant asInstant()
protected Value clone()
Copyright © 2023. All rights reserved.