Package org.apache.groovy.json.internal
Class NumberValue
- java.lang.Object
-
- java.lang.Number
-
- org.apache.groovy.json.internal.NumberValue
-
- All Implemented Interfaces:
Serializable
,Value
public class NumberValue extends Number implements Value
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description NumberValue()
NumberValue(boolean chop, Type type, int startIndex, int endIndex, char[] buffer)
NumberValue(Type type)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description BigDecimal
bigDecimalValue()
BigInteger
bigIntegerValue()
boolean
booleanValue()
byte
byteValue()
char
charValue()
void
chop()
Date
dateValue()
double
doubleValue()
boolean
equals(Object o)
float
floatValue()
int
hashCode()
int
intValue()
boolean
isContainer()
long
longValue()
short
shortValue()
String
stringValue()
String
stringValueEncoded()
<T extends Enum>
TtoEnum(Class<T> cls)
static <T extends Enum>
TtoEnum(Class<T> cls, int value)
String
toString()
Object
toValue()
-
-
-
Method Detail
-
isContainer
public boolean isContainer()
- Specified by:
isContainer
in interfaceValue
-
bigDecimalValue
public BigDecimal bigDecimalValue()
- Specified by:
bigDecimalValue
in interfaceValue
-
bigIntegerValue
public BigInteger bigIntegerValue()
- Specified by:
bigIntegerValue
in interfaceValue
-
stringValue
public String stringValue()
- Specified by:
stringValue
in interfaceValue
-
stringValueEncoded
public String stringValueEncoded()
- Specified by:
stringValueEncoded
in interfaceValue
-
intValue
public int intValue()
-
longValue
public long longValue()
-
byteValue
public byte byteValue()
-
shortValue
public short shortValue()
- Specified by:
shortValue
in interfaceValue
- Overrides:
shortValue
in classNumber
-
doubleValue
public double doubleValue()
- Specified by:
doubleValue
in interfaceValue
- Specified by:
doubleValue
in classNumber
-
booleanValue
public boolean booleanValue()
- Specified by:
booleanValue
in interfaceValue
-
floatValue
public float floatValue()
- Specified by:
floatValue
in interfaceValue
- Specified by:
floatValue
in classNumber
-
-