Class RGBColorValue
- java.lang.Object
-
- org.apache.batik.css.engine.value.AbstractValue
-
- org.apache.batik.css.engine.value.RGBColorValue
-
- All Implemented Interfaces:
Value
public class RGBColorValue extends AbstractValue
This class represents RGB colors.
-
-
Constructor Summary
Constructors Constructor Description RGBColorValue(Value r, Value g, Value b)
Creates a new RGBColorValue.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Value
getBlue()
ImplementsValue.getBlue()
.java.lang.String
getCssText()
A string representation of the current value.Value
getGreen()
ImplementsValue.getGreen()
.short
getPrimitiveType()
The type of the value.Value
getRed()
ImplementsValue.getRed()
.java.lang.String
toString()
Returns a printable representation of the color.-
Methods inherited from class org.apache.batik.css.engine.value.AbstractValue
createDOMException, getBottom, getCssValueType, getFloatValue, getIdentifier, getLeft, getLength, getListStyle, getRight, getSeparator, getStringValue, getTop, item
-
-
-
-
Method Detail
-
getPrimitiveType
public short getPrimitiveType()
The type of the value.- Specified by:
getPrimitiveType
in interfaceValue
- Overrides:
getPrimitiveType
in classAbstractValue
-
getCssText
public java.lang.String getCssText()
A string representation of the current value.
-
getRed
public Value getRed() throws org.w3c.dom.DOMException
ImplementsValue.getRed()
.- Specified by:
getRed
in interfaceValue
- Overrides:
getRed
in classAbstractValue
- Throws:
org.w3c.dom.DOMException
- INVALID_ACCESS_ERR: Raised if the value doesn't contain a RGB color value.
-
getGreen
public Value getGreen() throws org.w3c.dom.DOMException
ImplementsValue.getGreen()
.- Specified by:
getGreen
in interfaceValue
- Overrides:
getGreen
in classAbstractValue
- Throws:
org.w3c.dom.DOMException
- INVALID_ACCESS_ERR: Raised if the value doesn't contain a RGB color value.
-
getBlue
public Value getBlue() throws org.w3c.dom.DOMException
ImplementsValue.getBlue()
.- Specified by:
getBlue
in interfaceValue
- Overrides:
getBlue
in classAbstractValue
- Throws:
org.w3c.dom.DOMException
- INVALID_ACCESS_ERR: Raised if the value doesn't contain a RGB color value.
-
toString
public java.lang.String toString()
Returns a printable representation of the color.- Overrides:
toString
in classjava.lang.Object
-
-