Package com.kitfox.svg.xml
Class NumberWithUnits
- java.lang.Object
-
- com.kitfox.svg.xml.NumberWithUnits
-
- All Implemented Interfaces:
java.io.Serializable
public class NumberWithUnits extends java.lang.Object implements java.io.Serializable
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static long
serialVersionUID
(package private) int
unitType
static int
UT_CM
static int
UT_EM
static int
UT_EX
static int
UT_IN
static int
UT_MM
static int
UT_PC
static int
UT_PERCENT
static int
UT_PT
static int
UT_PX
static int
UT_UNITLESS
(package private) float
value
-
Constructor Summary
Constructors Constructor Description NumberWithUnits()
Creates a new instance of NumberWithUnitsNumberWithUnits(float value, int unitType)
NumberWithUnits(java.lang.String value)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(java.lang.Object obj)
int
getUnits()
float
getValue()
int
hashCode()
void
set(java.lang.String value)
java.lang.String
toString()
static java.lang.String
unitsAsString(int unitIdx)
-
-
-
Field Detail
-
serialVersionUID
public static final long serialVersionUID
- See Also:
- Constant Field Values
-
UT_UNITLESS
public static final int UT_UNITLESS
- See Also:
- Constant Field Values
-
UT_PX
public static final int UT_PX
- See Also:
- Constant Field Values
-
UT_CM
public static final int UT_CM
- See Also:
- Constant Field Values
-
UT_MM
public static final int UT_MM
- See Also:
- Constant Field Values
-
UT_IN
public static final int UT_IN
- See Also:
- Constant Field Values
-
UT_EM
public static final int UT_EM
- See Also:
- Constant Field Values
-
UT_EX
public static final int UT_EX
- See Also:
- Constant Field Values
-
UT_PT
public static final int UT_PT
- See Also:
- Constant Field Values
-
UT_PC
public static final int UT_PC
- See Also:
- Constant Field Values
-
UT_PERCENT
public static final int UT_PERCENT
- See Also:
- Constant Field Values
-
value
float value
-
unitType
int unitType
-
-
Method Detail
-
getValue
public float getValue()
-
getUnits
public int getUnits()
-
set
public void set(java.lang.String value)
-
unitsAsString
public static java.lang.String unitsAsString(int unitIdx)
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equals
in classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
-