-
- All Implemented Interfaces:
-
io.kjson.JSONPrimitive,io.kjson.JSONValue,java.io.Serializable
public final class JSONDecimal extends JSONNumberValue implements JSONPrimitive<BigDecimal>
A JSON decimal value - that is, a JSON number that is not an integer.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public classJSONDecimal.Companion
-
Field Summary
Fields Modifier and Type Field Description private final BigDecimalvalue
-
Constructor Summary
Constructors Constructor Description JSONDecimal(String str)JSONDecimal(Long long)JSONDecimal(Integer int)JSONDecimal(BigDecimal value)
-
Method Summary
Modifier and Type Method Description BigDecimalgetValue()StringtoJSON()UnitappendTo(Appendable a)BooleanisIntegral()BooleanisLong()BooleanisInt()BooleanisShort()BooleanisByte()BooleanisULong()BooleanisUInt()BooleanisUShort()BooleanisUByte()BooleanisZero()BooleanisNegative()BooleanisPositive()BooleanisNotZero()BooleanisNotNegative()BooleanisNotPositive()DoubletoDouble()FloattoFloat()LongtoLong()IntegertoInt()CharactertoChar()ShorttoShort()BytetoByte()BigDecimaltoDecimal()ULongtoULong()UInttoUInt()UShorttoUShort()UBytetoUByte()Booleanequals(Object other)IntegerhashCode()StringtoString()-
-
Constructor Detail
-
JSONDecimal
JSONDecimal(String str)
-
JSONDecimal
JSONDecimal(Long long)
-
JSONDecimal
JSONDecimal(Integer int)
-
JSONDecimal
JSONDecimal(BigDecimal value)
-
-
Method Detail
-
getValue
BigDecimal getValue()
-
appendTo
Unit appendTo(Appendable a)
-
isIntegral
Boolean isIntegral()
-
isNegative
Boolean isNegative()
-
isPositive
Boolean isPositive()
-
isNotNegative
Boolean isNotNegative()
-
isNotPositive
Boolean isNotPositive()
-
toDecimal
BigDecimal toDecimal()
-
-
-
-