java.lang.Object
io.sf.carte.echosvg.css.engine.value.AbstractValue
io.sf.carte.echosvg.css.engine.value.FloatValue
- All Implemented Interfaces:
Value
- Direct Known Subclasses:
LineHeightValue
This class represents float values.
-
Field Summary
Modifier and TypeFieldDescriptionprotected float
The float valueprotected static final String[]
The unit types representationsprotected short
The unit type -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionA string representation of the current value.static String
getCssText
(short unit, float value) Returns the CSS text associated with the given type/value pair.float
Returns the float value.short
The type of the value.toString()
Returns a printable representation of this value.Methods inherited from class io.sf.carte.echosvg.css.engine.value.AbstractValue
createDOMException, getAlpha, getBlue, getBottom, getCssValueType, getGreen, getIdentifier, getLeft, getLength, getListStyle, getRed, getRight, getSeparator, getStringValue, getTop, item
-
Field Details
-
UNITS
The unit types representations -
floatValue
protected float floatValueThe float value -
unitType
protected short unitTypeThe unit type
-
-
Constructor Details
-
FloatValue
public FloatValue(short unitType, float floatValue) Creates a new value.
-
-
Method Details
-
getCssText
Returns the CSS text associated with the given type/value pair. -
getPrimitiveType
public short getPrimitiveType()The type of the value.- Specified by:
getPrimitiveType
in interfaceValue
- Overrides:
getPrimitiveType
in classAbstractValue
-
getFloatValue
public float getFloatValue()Returns the float value.- Specified by:
getFloatValue
in interfaceValue
- Overrides:
getFloatValue
in classAbstractValue
-
getCssText
A string representation of the current value. -
toString
Returns a printable representation of this value.
-