public class TLcdSLDStroke extends TLcdDataObject
Modifier and Type | Field and Description |
---|---|
static String |
CSS_PARAMETER_MARKER_END |
static String |
CSS_PARAMETER_MARKER_START |
static String |
CSS_PARAMETER_STROKE |
static String |
CSS_PARAMETER_STROKE_DASHARRAY |
static String |
CSS_PARAMETER_STROKE_DASHOFFSET |
static String |
CSS_PARAMETER_STROKE_LINECAP |
static String |
CSS_PARAMETER_STROKE_LINEJOIN |
static String |
CSS_PARAMETER_STROKE_OPACITY |
static String |
CSS_PARAMETER_STROKE_WIDTH |
Constructor and Description |
---|
TLcdSLDStroke()
Constructor.
|
TLcdSLDStroke(TLcdDataType aDataType)
Constructor.
|
TLcdSLDStroke(TLcdSLDGraphic aGraphicFill,
TLcdSLDGraphic aGraphicStroke)
Constructor for either a given fill or a stroke.
|
Modifier and Type | Method and Description |
---|---|
protected boolean |
acceptParameterName(String aParameterName)
Checks whether the given CSS parameter name would be accepted when set.
|
TLcdDataObject |
clone()
Returns a deep clone of this object.
|
TLcdDataObject |
clone(Map aObjectDictionary)
Returns a deep clone of this object.
|
TLcdSLDParameterValue |
getCssParameter(String aParameterName)
Returns the value of the parameter with name aName where aName is a field constant of this class
|
TLcdSLDGraphic |
getGraphicFill()
Returns the value of the property that maps to the
GraphicFill element. |
TLcdSLDGraphic |
getGraphicStroke()
Returns the value of the property that maps to the
GraphicStroke element. |
TLcdSLDParameterValue |
getGraphicStrokeGap()
Returns the value of the property that maps to the
GraphicStrokeGap element. |
TLcdSLDParameterValue |
getGraphicStrokeInitialGap()
Returns the value of the property that maps to the
GraphicStrokeInitialGap element. |
Object |
getValue(TLcdDataProperty aProperty)
Returns the value of the given property.
|
void |
setCssParameter(String aParameterName,
TLcdSLDParameterValue aParameterValue)
Sets the value of the parameter with name aName where aName is a field constant of
TLcdSLDStroke . |
void |
setGraphicFill(TLcdSLDGraphic aGraphicFill)
Sets the graphic with which the stroke will have to be stipple filled.
|
void |
setGraphicStroke(TLcdSLDGraphic aGraphicStroke)
Sets the graphic with which the stroke will have to be filled repeated linearly.
|
void |
setGraphicStrokeGap(TLcdSLDParameterValue aValue)
Sets the value of the property that maps to the
GraphicStrokeGap element. |
void |
setGraphicStrokeInitialGap(TLcdSLDParameterValue aValue)
Sets the value of the property that maps to the
GraphicStrokeInitialGap element. |
void |
setValue(TLcdDataProperty aProperty,
Object aValue)
Sets the value of the given property for this data object.
|
getDataType, getValue, hasValue, hasValue, setValue, toString
public static final String CSS_PARAMETER_STROKE
public static final String CSS_PARAMETER_STROKE_DASHARRAY
public static final String CSS_PARAMETER_STROKE_DASHOFFSET
public static final String CSS_PARAMETER_STROKE_LINECAP
public static final String CSS_PARAMETER_STROKE_LINEJOIN
public static final String CSS_PARAMETER_STROKE_OPACITY
public static final String CSS_PARAMETER_STROKE_WIDTH
public static final String CSS_PARAMETER_MARKER_START
public static final String CSS_PARAMETER_MARKER_END
public TLcdSLDStroke()
public TLcdSLDStroke(TLcdSLDGraphic aGraphicFill, TLcdSLDGraphic aGraphicStroke)
null
-value for the stroking-type
that needs to be disabled.aGraphicFill
- the given graphic fill.aGraphicStroke
- the given graphic stroke.public TLcdSLDStroke(TLcdDataType aDataType)
public void setGraphicFill(TLcdSLDGraphic aGraphicFill)
aGraphicFill
- the graphic fill.public void setGraphicStroke(TLcdSLDGraphic aGraphicStroke)
aGraphicStroke
- the graphic stroke.public void setCssParameter(String aParameterName, TLcdSLDParameterValue aParameterValue)
TLcdSLDStroke
.
Note that there is no check here of the values passed, since that is not possible when the
parameter value type contains an expression.aParameterName
- the name of the CSS parameter, this should be one of the constant field values. Passing
another name will cause an IllegalArgumentExceptionaParameterValue
- the value that is to be setIllegalArgumentException
- when a parameter with an invalid name is passed.acceptParameterName(String)
public void setValue(TLcdDataProperty aProperty, Object aValue)
ILcdDataObject
Sets the value of the given property for this data object. The implementation is allowed to throw an exception if the given value can't be set.
The given property must be declared in thedata object's type
or in one of its super types. In
other words, getDataType().getProperties().contains( aProperty ) should always be true.
Otherwise, the implementation should throw an IllegalArgumentException
.setValue
in interface ILcdDataObject
setValue
in class TLcdDataObject
aProperty
- the property for which the value is to be setaValue
- the value to setTLcdDataType.getProperty(String)
public Object getValue(TLcdDataProperty aProperty)
ILcdDataObject
Returns the value of the given property.
If the property is a collection, the returned value will never be null. If the property has not been set, an empty collection of the appropriate type will be returned (Set, List or Map).
The property must not be null, and must be declared in the data object's type
or in one of its super types.
Otherwise an IllegalArgumentException
is thrown.
getValue
in interface ILcdDataObject
getValue
in class TLcdDataObject
aProperty
- the property for which the value is to be returnedpublic TLcdSLDParameterValue getCssParameter(String aParameterName)
aParameterName
- the parameter for which the value is required.protected boolean acceptParameterName(String aParameterName)
aParameterName
- the name of the CSS parameter.public TLcdDataObject clone()
TLcdDataObject
TLcdDataObject.clone(Map)
.clone
in interface ILcdCloneable
clone
in class TLcdDataObject
Object.clone()
public TLcdDataObject clone(Map aObjectDictionary)
TLcdDataObject
ILcdDataObject
, the value is cloned by first creating a new instance via
the value.getDataType().newInstance()
method, and then cloning its properties one by one.ILcdDeepCloneable
or
ILcdCloneable
then this interface is used to clone the value.clone
in interface ILcdDeepCloneable
clone
in class TLcdDataObject
aObjectDictionary
- the Object dictionary that keeps track of the objects for which a clone has already been made,
and their corresponding clone Object.public TLcdSLDGraphic getGraphicFill()
GraphicFill
element.
A "GraphicFill" defines repeated-graphic filling (stippling) pattern for an area geometry.
GRAPHIC_FILL_PROPERTY
property.public TLcdSLDGraphic getGraphicStroke()
GraphicStroke
element.
A "GraphicStroke" defines a repated-linear graphic pattern to be used for stroking a line.
GRAPHIC_STROKE_PROPERTY
property.public TLcdSLDParameterValue getGraphicStrokeInitialGap()
GraphicStrokeInitialGap
element.
Initial gap defines the initial empty space, before the first Graphic or Label should be rendered.
GRAPHIC_STROKE_INITIAL_GAP_PROPERTY
property.public void setGraphicStrokeInitialGap(TLcdSLDParameterValue aValue)
GraphicStrokeInitialGap
element.
Initial gap defines the initial empty space, before the first Graphic or Label should be rendered.
aValue
- the value to set for the GRAPHIC_STROKE_INITIAL_GAP_PROPERTY
property.public TLcdSLDParameterValue getGraphicStrokeGap()
GraphicStrokeGap
element.
Gap defines the empty space between two Graphics or Labels.
GRAPHIC_STROKE_GAP_PROPERTY
property.public void setGraphicStrokeGap(TLcdSLDParameterValue aValue)
GraphicStrokeGap
element.
Gap defines the empty space between two Graphics or Labels.
aValue
- the value to set for the GRAPHIC_STROKE_GAP_PROPERTY
property.