Package org.geotools.styling
Class MarkImpl
Object
MarkImpl
- All Implemented Interfaces:
Cloneable
,GraphicalSymbol
,Mark
,Symbol
,Cloneable
Default implementation of Mark.
- Author:
- Ian Turton, CCG, Johann Sorel (Geomatys)
-
Field Summary
Fields inherited from interface GraphicalSymbol
SYMBOLS_EMPTY
Fields inherited from interface Mark
MARKS_EMPTY
Fields inherited from interface Symbol
SYMBOLS_EMPTY
-
Constructor Summary
ConstructorsConstructorDescriptionMarkImpl()
Creates a new instance of DefaultMarkMarkImpl
(FilterFactory filterFactory, ExternalMark external) -
Method Summary
Modifier and TypeMethodDescriptionvoid
accept
(StyleVisitor visitor) calls the visit method of a StyleVisitoraccept
(TraversingStyleVisitor visitor, Object data) clone()
Creates a deep copy of the Mark.boolean
Compares this MarkImpl with another for equality.The alternative to a WellKnownName is an external mark format.getFill()
This parameter defines which fill style to use when rendering the Mark.This paramterer defines which stroke style should be used when rendering the Mark.This parameter gives the well-known name of the shape of the mark.
Allowed names include at least "square", "circle", "triangle", "star", "cross" and "x" though renderers may draw a different symbol instead if they don't have a shape for all of these.int
hashCode()
The hashcode override for the MarkImpl.void
setExternalMark
(ExternalMark external) Mark defined by an external resource.void
Setter for property fill.void
Setter for property stroke.void
setWellKnownName
(String name) void
setWellKnownName
(Expression wellKnownName) Setter for property wellKnownName.toString()
-
Constructor Details
-
MarkImpl
public MarkImpl()Creates a new instance of DefaultMark -
MarkImpl
-
MarkImpl
-
-
Method Details
-
getFill
This parameter defines which fill style to use when rendering the Mark. -
getStroke
This paramterer defines which stroke style should be used when rendering the Mark. -
getWellKnownName
This parameter gives the well-known name of the shape of the mark.
Allowed names include at least "square", "circle", "triangle", "star", "cross" and "x" though renderers may draw a different symbol instead if they don't have a shape for all of these.- Specified by:
getWellKnownName
in interfaceMark
- Returns:
- The well-known name of a shape. The default value is "square".
-
setFill
Setter for property fill. -
setStroke
Setter for property stroke. -
setWellKnownName
Setter for property wellKnownName.- Specified by:
setWellKnownName
in interfaceMark
- Parameters:
wellKnownName
- New value of property wellKnownName.
-
setWellKnownName
-
toString
-
accept
-
accept
Description copied from interface:Mark
calls the visit method of a StyleVisitor -
clone
Creates a deep copy of the Mark.Only the fill and stroke are cloned since Expressions should be immutable.
-
hashCode
public int hashCode()The hashcode override for the MarkImpl. -
equals
Compares this MarkImpl with another for equality.Two MarkImpls are equal if they have the same well Known Name, the same size and rotation and the same stroke and fill.
-
getExternalMark
Description copied from interface:Mark
The alternative to a WellKnownName is an external mark format. SeeExternalMark
for details.Both WellKnowName and ExternalMark cannot be set, but both can be null. If none are set then the default square symbol is used.
- Specified by:
getExternalMark
in interfaceMark
- Returns:
- ExternalMark or null
-
setExternalMark
Description copied from interface:Mark
Mark defined by an external resource.- Specified by:
setExternalMark
in interfaceMark
- Parameters:
external
- Indicate an mark defined by an external resource
-