|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.apache.batik.css.value.AbstractValueFactory
This class provides a base implementation for every value factories.
Inner Class Summary | |
protected class |
AbstractValueFactory.StringFactory
To create string values. |
protected class |
AbstractValueFactory.URIFactory
To manage the uri values. |
Field Summary | |
protected ExtendedParser |
parser
The CSS parser. |
Constructor Summary | |
protected |
AbstractValueFactory(Parser p)
To creates a new ValueFactory object. |
Method Summary | |
protected CSSOMValue |
createCSSValue(ImmutableValue v)
Creates a new CSSValue. |
void |
createCSSValue(LexicalUnit lu,
CSSOMStyleDeclaration d,
java.lang.String imp)
Creates a value from a lexical unit and a style declaration. |
ImmutableValue |
createFloatValue(short unitType,
float floatValue)
Creates and returns a new float value. |
ImmutableValue |
createStringValue(short type,
java.lang.String value)
Creates and returns a new string value. |
ImmutableValue |
createValue(java.lang.String text)
Creates a value from its text representation |
Parser |
getParser()
Returns the CSS parser. |
void |
setParser(Parser p)
Sets the parser used by this factory. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.apache.batik.css.value.ValueFactory |
createValue, getPropertyName |
Field Detail |
protected ExtendedParser parser
Constructor Detail |
protected AbstractValueFactory(Parser p)
p
- The CSS parser used to parse the CSS texts.Method Detail |
public Parser getParser()
public void setParser(Parser p)
setParser
in interface ValueFactory
public ImmutableValue createValue(java.lang.String text) throws DOMException
createValue
in interface ValueFactory
text
- The text that represents the CSS value to create.public void createCSSValue(LexicalUnit lu, CSSOMStyleDeclaration d, java.lang.String imp) throws DOMException
createCSSValue
in interface ValueFactory
lu
- The SAC lexical unit used to create the value.d
- The style declaration in which to add the created value.imp
- The property priority.public ImmutableValue createFloatValue(short unitType, float floatValue) throws DOMException
createFloatValue
in interface ValueFactory
unitType
- A unit code as defined above. The unit code can only
be a float unit typefloatValue
- The new float value.public ImmutableValue createStringValue(short type, java.lang.String value) throws DOMException
createStringValue
in interface ValueFactory
type
- A string code as defined in CSSPrimitiveValue. The string
code can only be a string unit type.value
- The new string value.protected CSSOMValue createCSSValue(ImmutableValue v)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |