Package org.apache.fop.fo.properties
Class ColorProperty
- java.lang.Object
-
- org.apache.fop.fo.properties.Property
-
- org.apache.fop.fo.properties.ColorProperty
-
public final class ColorProperty extends Property
Class for properties that wrap Color values
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
ColorProperty.Maker
Inner class for creating instances of ColorTypeProperty
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(java.lang.Object o)
java.awt.Color
getColor(FOUserAgent foUserAgent)
Returns an AWT instance of this colorColorProperty
getColorProperty()
Can't convert to any other typesstatic ColorProperty
getInstance(FOUserAgent foUserAgent, java.lang.String value)
Set the color given a particular String.java.lang.Object
getObject()
This method expects to be overridden by subclassesint
hashCode()
java.lang.String
toString()
-
Methods inherited from class org.apache.fop.fo.properties.Property
getCharacter, getCondLength, getEnum, getKeep, getLength, getLengthPair, getLengthRange, getList, getNCname, getNumber, getNumeric, getSpace, getSpecifiedValue, getString, isAuto, setSpecifiedValue
-
-
-
-
Method Detail
-
getInstance
public static ColorProperty getInstance(FOUserAgent foUserAgent, java.lang.String value) throws PropertyException
Set the color given a particular String. For a full List of supported values please see ColorUtil.- Parameters:
foUserAgent
- FOP user agentvalue
- RGB value as String to be parsed- Returns:
- the canonical ColorProperty instance corresponding to the given value
- Throws:
PropertyException
- if the value can't be parsed- See Also:
ColorUtil.parseColorString(FOUserAgent, String)
-
getColor
public java.awt.Color getColor(FOUserAgent foUserAgent)
Returns an AWT instance of this color
-
getColorProperty
public ColorProperty getColorProperty()
Can't convert to any other types- Returns:
- this.colorType
-
getObject
public java.lang.Object getObject()
Description copied from class:Property
This method expects to be overridden by subclasses
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equals
in classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
-