|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.apache.batik.parser.style.AbstractCSSValue
This class implements the CSSValue
,
CSSPrimitiveValue
,
CSSValueList
interfaces.
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 | |
AbstractCSSValue()
|
Method Summary | |
Counter |
getCounterValue()
DOM: Implements CSSPrimitiveValue.getCounterValue() . |
float |
getFloatValue(short unitType)
DOM: Implements CSSPrimitiveValue.getFloatValue(short) . |
int |
getLength()
DOM: Implements CSSValueList.getLength() . |
short |
getPrimitiveType()
DOM: Implements CSSPrimitiveValue.getPrimitiveType() . |
Rect |
getRectValue()
DOM: Implements CSSPrimitiveValue.getRectValue() . |
RGBColor |
getRGBColorValue()
DOM: Implements CSSPrimitiveValue.getRGBColorValue() . |
java.lang.String |
getStringValue()
DOM: Implements CSSPrimitiveValue.getStringValue() . |
CSSValue |
item(int index)
DOM: Implements CSSValueList.item(int) . |
void |
setCssText(java.lang.String cssText)
DOM: Implements CSSValue.setCssText(String) .
|
void |
setFloatValue(short unitType,
float floatValue)
DOM: Implements CSSPrimitiveValue.setFloatValue(short,float) .
|
void |
setStringValue(short stringType,
java.lang.String stringValue)
DOM: Implements CSSPrimitiveValue.setStringValue(short,String) .
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.w3c.dom.css.CSSValue |
getCssText, getCssValueType |
Constructor Detail |
public AbstractCSSValue()
Method Detail |
public short getPrimitiveType()
CSSPrimitiveValue.getPrimitiveType()
.getPrimitiveType
in interface CSSPrimitiveValue
public void setCssText(java.lang.String cssText) throws DOMException
CSSValue.setCssText(String)
.
Throws a NO_MODIFICATION_ALLOWED_ERR DOMException
.setCssText
in interface CSSValue
org.w3c.dom.css.CSSValue
DOMException
- SYNTAX_ERR: Raised if the specified CSS string value has a syntax
error (according to the attached property) or is unparsable.
public void setFloatValue(short unitType, float floatValue) throws DOMException
CSSPrimitiveValue.setFloatValue(short,float)
.
Throws a NO_MODIFICATION_ALLOWED_ERR DOMException
.setFloatValue
in interface CSSPrimitiveValue
org.w3c.dom.css.CSSPrimitiveValue
unitType
- A unit code as defined above. The unit code can only
be a float unit type (i.e. CSS_NUMBER
,
CSS_PERCENTAGE
, CSS_EMS
,
CSS_EXS
, CSS_PX
, CSS_CM
,
CSS_MM
, CSS_IN
, CSS_PT
,
CSS_PC
, CSS_DEG
, CSS_RAD
,
CSS_GRAD
, CSS_MS
, CSS_S
,
CSS_HZ
, CSS_KHZ
,
CSS_DIMENSION
).floatValue
- The new float value.DOMException
- INVALID_ACCESS_ERR: Raised if the attached property doesn't support
the float value or the unit type.
public float getFloatValue(short unitType) throws DOMException
CSSPrimitiveValue.getFloatValue(short)
.getFloatValue
in interface CSSPrimitiveValue
org.w3c.dom.css.CSSPrimitiveValue
unitType
- A unit code to get the float value. The unit code can
only be a float unit type (i.e. CSS_NUMBER
,
CSS_PERCENTAGE
, CSS_EMS
,
CSS_EXS
, CSS_PX
, CSS_CM
,
CSS_MM
, CSS_IN
, CSS_PT
,
CSS_PC
, CSS_DEG
, CSS_RAD
,
CSS_GRAD
, CSS_MS
, CSS_S
,
CSS_HZ
, CSS_KHZ
,
CSS_DIMENSION
).DOMException
- INVALID_ACCESS_ERR: Raised if the CSS value doesn't contain a float
value or if the float value can't be converted into the specified
unit.public void setStringValue(short stringType, java.lang.String stringValue) throws DOMException
CSSPrimitiveValue.setStringValue(short,String)
.
Throws a NO_MODIFICATION_ALLOWED_ERR DOMException
.setStringValue
in interface CSSPrimitiveValue
org.w3c.dom.css.CSSPrimitiveValue
stringType
- A string code as defined above. The string code can
only be a string unit type (i.e. CSS_STRING
,
CSS_URI
, CSS_IDENT
, and
CSS_ATTR
).stringValue
- The new string value.DOMException
- INVALID_ACCESS_ERR: Raised if the CSS value doesn't contain a string
value or if the string value can't be converted into the specified
unit.
public java.lang.String getStringValue() throws DOMException
CSSPrimitiveValue.getStringValue()
.getStringValue
in interface CSSPrimitiveValue
org.w3c.dom.css.CSSPrimitiveValue
primitiveType
can only be a string unit type (i.e.
CSS_STRING
, CSS_URI
,
CSS_IDENT
and CSS_ATTR
).DOMException
- INVALID_ACCESS_ERR: Raised if the CSS value doesn't contain a string
value.public Counter getCounterValue() throws DOMException
CSSPrimitiveValue.getCounterValue()
.getCounterValue
in interface CSSPrimitiveValue
org.w3c.dom.css.CSSPrimitiveValue
DOMException
- INVALID_ACCESS_ERR: Raised if the CSS value doesn't contain a
Counter value (e.g. this is not CSS_COUNTER
).public Rect getRectValue() throws DOMException
CSSPrimitiveValue.getRectValue()
.getRectValue
in interface CSSPrimitiveValue
org.w3c.dom.css.CSSPrimitiveValue
DOMException
- INVALID_ACCESS_ERR: Raised if the CSS value doesn't contain a Rect
value. (e.g. this is not CSS_RECT
).public RGBColor getRGBColorValue() throws DOMException
CSSPrimitiveValue.getRGBColorValue()
.getRGBColorValue
in interface CSSPrimitiveValue
org.w3c.dom.css.CSSPrimitiveValue
DOMException
- INVALID_ACCESS_ERR: Raised if the attached property can't return a
RGB color value (e.g. this is not CSS_RGBCOLOR
).public int getLength()
CSSValueList.getLength()
.getLength
in interface CSSValueList
public CSSValue item(int index)
CSSValueList.item(int)
.item
in interface CSSValueList
org.w3c.dom.css.CSSValueList
index
- Index into the collection.CSSValue
at the index
position
in the CSSValueList
, or null
if that is
not a valid index.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |