java.lang.Object
io.sf.carte.echosvg.css.dom.CSSOMValue
- All Implemented Interfaces:
Counter
,CSSPrimitiveValue
,CSSValue
,CSSValueList
,Rect
,RGBColor
- Direct Known Subclasses:
CSSOMComputedStyle.ComputedCSSValue
,CSSOMStyleDeclaration.StyleDeclarationValue
,SVGStylableElement.PresentationAttributeValue
public class CSSOMValue
extends Object
implements CSSPrimitiveValue, CSSValueList, Counter, Rect, RGBColor
-
Nested Class Summary
Modifier and TypeClassDescriptionprotected class
To store a component.static class
This class provides an abstract implementation of a ModificationHandler.protected class
To represents an alpha component.protected class
To represents a blue component.protected class
To represents a bottom component.protected class
To store a Float component.protected class
To represents a green component.protected class
To represents a left component.protected class
To represents a List component.static interface
To manage the modifications on a CSS value.protected class
To represents a red component.protected class
To represents a right component.protected class
To represents a top component.static interface
To provides the actual value. -
Field Summary
Modifier and TypeFieldDescriptionprotected CSSOMValue.AlphaComponent
The alpha component, if this value is a RGBColor.protected CSSOMValue.BlueComponent
The blue component, if this value is a RGBColor.protected CSSOMValue.BottomComponent
The bottom component, if this value is a Rect.protected CSSOMValue.GreenComponent
The green component, if this value is a RGBColor.protected CSSOMValue.ModificationHandler
The modifications handler.protected CSSValue[]
The list items.protected CSSOMValue.LeftComponent
The left component, if this value is a Rect.protected CSSOMValue.RedComponent
The red component, if this value is a RGBColor.protected CSSOMValue.RightComponent
The right component, if this value is a Rect.protected CSSOMValue.TopComponent
The top component, if this value is a Rect.protected CSSOMValue.ValueProvider
The associated value.Fields inherited from interface org.w3c.dom.css.CSSPrimitiveValue
CSS_ATTR, CSS_CM, CSS_COUNTER, CSS_DEG, CSS_DIMENSION, CSS_EMS, CSS_EXS, CSS_GRAD, CSS_HZ, CSS_IDENT, CSS_IN, CSS_KHZ, CSS_MM, CSS_MS, CSS_NUMBER, CSS_PC, CSS_PERCENTAGE, CSS_PT, CSS_PX, CSS_RAD, CSS_RECT, CSS_RGBCOLOR, CSS_S, CSS_STRING, CSS_UNKNOWN, CSS_URI
Fields inherited from interface org.w3c.dom.css.CSSValue
CSS_CUSTOM, CSS_INHERIT, CSS_PRIMITIVE_VALUE, CSS_VALUE_LIST
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic float
convertFloatValue
(short unitType, Value value) Converts the actual float value to the given unit type.getAlpha()
getBlue()
DOM: ImplementsRGBColor.getBlue()
.DOM: ImplementsRect.getBottom()
.DOM: ImplementsCSSPrimitiveValue.getCounterValue()
.DOM: ImplementsCSSValue.getCssText()
.short
DOM: ImplementsCSSValue.getCssValueType()
.float
getFloatValue
(short unitType) DOM: ImplementsCSSPrimitiveValue.getFloatValue(short)
.getGreen()
DOM: ImplementsRGBColor.getGreen()
.DOM: ImplementsCounter.getIdentifier()
.getLeft()
DOM: ImplementsRect.getLeft()
.int
DOM: ImplementsCSSValueList.getLength()
.DOM: ImplementsCounter.getListStyle()
.short
DOM: ImplementsCSSPrimitiveValue.getPrimitiveType()
.DOM: ImplementsCSSPrimitiveValue.getRectValue()
.getRed()
DOM: ImplementsRGBColor.getRed()
.DOM: ImplementsCSSPrimitiveValue.getRGBColorValue()
.getRight()
DOM: ImplementsRect.getRight()
.DOM: ImplementsCounter.getSeparator()
.DOM: ImplementsCSSPrimitiveValue.getStringValue()
.getTop()
DOM: ImplementsRect.getTop()
.item
(int index) DOM: ImplementsCSSValueList.item(int)
.void
setCssText
(String cssText) DOM: ImplementsCSSValue.setCssText(String)
.void
setFloatValue
(short unitType, float floatValue) DOM: ImplementsCSSPrimitiveValue.setFloatValue(short,float)
.void
Sets the modification handler of this value.void
setStringValue
(short stringType, String stringValue) DOM: ImplementsCSSPrimitiveValue.setStringValue(short,String)
.protected static float
toCentimeters
(Value value) Converts the current value into centimeters.protected static float
Converts the current value into degrees.protected static float
toGradians
(Value value) Converts the current value into gradians.protected static float
Converts the current value into Hertz.protected static float
Converts the current value into inches.protected static float
Converts the current value into kHertz.protected static float
toMillimeters
(Value value) Converts the current value into millimeters.protected static float
toMilliseconds
(Value value) Converts the current value into milliseconds.protected static float
Converts the current value into picas.protected static float
Converts the current value into points.protected static float
Converts the current value into radians.protected static float
Converts the current value into seconds.
-
Field Details
-
valueProvider
The associated value. -
handler
The modifications handler. -
leftComponent
The left component, if this value is a Rect. -
rightComponent
The right component, if this value is a Rect. -
bottomComponent
The bottom component, if this value is a Rect. -
topComponent
The top component, if this value is a Rect. -
redComponent
The red component, if this value is a RGBColor. -
greenComponent
The green component, if this value is a RGBColor. -
blueComponent
The blue component, if this value is a RGBColor. -
alphaComponent
The alpha component, if this value is a RGBColor. -
items
The list items.
-
-
Constructor Details
-
CSSOMValue
Creates a new CSSOMValue.
-
-
Method Details
-
setModificationHandler
Sets the modification handler of this value. -
getCssText
DOM: ImplementsCSSValue.getCssText()
.- Specified by:
getCssText
in interfaceCSSValue
-
setCssText
DOM: ImplementsCSSValue.setCssText(String)
.- Specified by:
setCssText
in interfaceCSSValue
- Throws:
DOMException
-
getCssValueType
public short getCssValueType()DOM: ImplementsCSSValue.getCssValueType()
.- Specified by:
getCssValueType
in interfaceCSSValue
-
getPrimitiveType
public short getPrimitiveType()DOM: ImplementsCSSPrimitiveValue.getPrimitiveType()
.- Specified by:
getPrimitiveType
in interfaceCSSPrimitiveValue
-
setFloatValue
DOM: ImplementsCSSPrimitiveValue.setFloatValue(short,float)
.- Specified by:
setFloatValue
in interfaceCSSPrimitiveValue
- Throws:
DOMException
-
getFloatValue
DOM: ImplementsCSSPrimitiveValue.getFloatValue(short)
.- Specified by:
getFloatValue
in interfaceCSSPrimitiveValue
- Throws:
DOMException
-
convertFloatValue
Converts the actual float value to the given unit type. -
toCentimeters
Converts the current value into centimeters. -
toInches
Converts the current value into inches. -
toMillimeters
Converts the current value into millimeters. -
toPoints
Converts the current value into points. -
toPicas
Converts the current value into picas. -
toDegrees
Converts the current value into degrees. -
toRadians
Converts the current value into radians. -
toGradians
Converts the current value into gradians. -
toMilliseconds
Converts the current value into milliseconds. -
toSeconds
Converts the current value into seconds. -
toHertz
Converts the current value into Hertz. -
tokHertz
Converts the current value into kHertz. -
setStringValue
DOM: ImplementsCSSPrimitiveValue.setStringValue(short,String)
.- Specified by:
setStringValue
in interfaceCSSPrimitiveValue
- Throws:
DOMException
-
getStringValue
DOM: ImplementsCSSPrimitiveValue.getStringValue()
.- Specified by:
getStringValue
in interfaceCSSPrimitiveValue
- Throws:
DOMException
-
getCounterValue
DOM: ImplementsCSSPrimitiveValue.getCounterValue()
.- Specified by:
getCounterValue
in interfaceCSSPrimitiveValue
- Throws:
DOMException
-
getRectValue
DOM: ImplementsCSSPrimitiveValue.getRectValue()
.- Specified by:
getRectValue
in interfaceCSSPrimitiveValue
- Throws:
DOMException
-
getRGBColorValue
DOM: ImplementsCSSPrimitiveValue.getRGBColorValue()
.- Specified by:
getRGBColorValue
in interfaceCSSPrimitiveValue
- Throws:
DOMException
-
getLength
public int getLength()DOM: ImplementsCSSValueList.getLength()
.- Specified by:
getLength
in interfaceCSSValueList
-
item
DOM: ImplementsCSSValueList.item(int)
.- Specified by:
item
in interfaceCSSValueList
-
getIdentifier
DOM: ImplementsCounter.getIdentifier()
.- Specified by:
getIdentifier
in interfaceCounter
-
getListStyle
DOM: ImplementsCounter.getListStyle()
.- Specified by:
getListStyle
in interfaceCounter
-
getSeparator
DOM: ImplementsCounter.getSeparator()
.- Specified by:
getSeparator
in interfaceCounter
-
getTop
DOM: ImplementsRect.getTop()
. -
getRight
DOM: ImplementsRect.getRight()
. -
getBottom
DOM: ImplementsRect.getBottom()
. -
getLeft
DOM: ImplementsRect.getLeft()
. -
getRed
DOM: ImplementsRGBColor.getRed()
. -
getGreen
DOM: ImplementsRGBColor.getGreen()
. -
getBlue
DOM: ImplementsRGBColor.getBlue()
. -
getAlpha
-