Package com.thingworx.types.primitives
Class NumberPrimitive
- java.lang.Object
-
- com.thingworx.types.primitives.NumberPrimitive
-
- All Implemented Interfaces:
IPrimitiveType<NumberPrimitive,java.lang.Double>
,java.io.Serializable
,java.lang.Cloneable
,java.lang.Comparable
,java.util.Comparator<NumberPrimitive>
@ThingworxExtensionApiClass(since={6,6}, canInstantiate=true) public final class NumberPrimitive extends java.lang.Object implements IPrimitiveType<NumberPrimitive,java.lang.Double>, java.lang.Cloneable
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description NumberPrimitive()
NumberPrimitive(java.lang.Double value)
Deprecated.NumberPrimitive(java.lang.Integer value)
Deprecated.NumberPrimitive(java.lang.Long value)
Deprecated.NumberPrimitive(java.lang.Number value)
Creates a new primitive that storesDouble
values.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description NumberPrimitive
clone()
int
compare(NumberPrimitive v1, NumberPrimitive v2)
int
compareTo(java.lang.Object value)
static NumberPrimitive
convertFromObject(java.lang.Object data)
Deprecated.BaseTypes
getBaseType()
java.lang.Object
getSerializedValue()
java.lang.String
getStringValue()
java.lang.Double
getValue()
void
setValue(java.lang.Double value)
-
-
-
Constructor Detail
-
NumberPrimitive
@ThingworxExtensionApiMethod(since={6,6}) public NumberPrimitive()
-
NumberPrimitive
@Deprecated @ThingworxExtensionApiMethod(since={6,6}, deprecatedSince={8,1}) public NumberPrimitive(java.lang.Integer value)
Deprecated.
-
NumberPrimitive
@Deprecated @ThingworxExtensionApiMethod(since={6,6}, deprecatedSince={8,1}) public NumberPrimitive(java.lang.Long value)
Deprecated.
-
NumberPrimitive
@Deprecated @ThingworxExtensionApiMethod(since={6,6}, deprecatedSince={8,1}) public NumberPrimitive(java.lang.Double value)
Deprecated.
-
NumberPrimitive
@ThingworxExtensionApiMethod(since={8,1}) public NumberPrimitive(java.lang.Number value)
Creates a new primitive that storesDouble
values.- Parameters:
value
- the number to store in the primitive
-
-
Method Detail
-
getBaseType
@ThingworxExtensionApiMethod(since={6,6}) public BaseTypes getBaseType()
- Specified by:
getBaseType
in interfaceIPrimitiveType<NumberPrimitive,java.lang.Double>
-
getValue
@ThingworxExtensionApiMethod(since={6,6}) public java.lang.Double getValue()
- Specified by:
getValue
in interfaceIPrimitiveType<NumberPrimitive,java.lang.Double>
-
setValue
@ThingworxExtensionApiMethod(since={6,6}) public void setValue(java.lang.Double value)
- Specified by:
setValue
in interfaceIPrimitiveType<NumberPrimitive,java.lang.Double>
-
getSerializedValue
@ThingworxExtensionApiMethod(since={6,6}) public java.lang.Object getSerializedValue()
- Specified by:
getSerializedValue
in interfaceIPrimitiveType<NumberPrimitive,java.lang.Double>
-
compareTo
@ThingworxExtensionApiMethod(since={6,6}) public int compareTo(java.lang.Object value)
- Specified by:
compareTo
in interfacejava.lang.Comparable
-
compare
@ThingworxExtensionApiMethod(since={6,6}) public int compare(NumberPrimitive v1, NumberPrimitive v2)
- Specified by:
compare
in interfacejava.util.Comparator<NumberPrimitive>
-
convertFromObject
@Deprecated @ThingworxExtensionApiMethod(since={6,6}) public static NumberPrimitive convertFromObject(java.lang.Object data) throws java.lang.Exception
Deprecated.- Throws:
java.lang.Exception
- If an error occurs
-
clone
@ThingworxExtensionApiMethod(since={6,6}) public NumberPrimitive clone()
- Specified by:
clone
in interfaceIPrimitiveType<NumberPrimitive,java.lang.Double>
- Overrides:
clone
in classjava.lang.Object
-
getStringValue
@ThingworxExtensionApiMethod(since={6,6}) public java.lang.String getStringValue()
- Specified by:
getStringValue
in interfaceIPrimitiveType<NumberPrimitive,java.lang.Double>
-
-