Package org.geotools.api.style
Interface Mark
-
- All Superinterfaces:
GraphicalSymbol
,Symbol
- All Known Implementing Classes:
MarkImpl
public interface Mark extends GraphicalSymbol, Symbol
Indicate that one of a few predefined shapes will be drawn at the points of the geometry.- Since:
- GeoAPI 2.2
- Author:
- Open Geospatial Consortium, Johann Sorel (Geomatys), Chris Dillard (SYS Technologies)
-
-
Field Summary
Fields Modifier and Type Field Description static Mark[]
MARKS_EMPTY
-
Fields inherited from interface GraphicalSymbol
SYMBOLS_EMPTY
-
Fields inherited from interface Symbol
SYMBOLS_EMPTY
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
accept(StyleVisitor visitor)
calls the visit method of a StyleVisitorObject
accept(TraversingStyleVisitor visitor, Object data)
ExternalMark
getExternalMark()
The alternative to a WellKnownName is an external mark format.Fill
getFill()
Returns the object that indicates how the mark should be filled.Stroke
getStroke()
Returns the object that indicates how the edges of the mark will be drawn.Expression
getWellKnownName()
Returns the expression whose value will indicate the symbol to draw.void
setExternalMark(ExternalMark externalMark)
Mark defined by an external resource.void
setFill(Fill fill)
This parameter defines which fill style to use when rendering the Mark.void
setStroke(Stroke stroke)
This paramterer defines which stroke style should be used when rendering the Mark.void
setWellKnownName(Expression wellKnownName)
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.
-
-
-
Field Detail
-
MARKS_EMPTY
static final Mark[] MARKS_EMPTY
-
-
Method Detail
-
getWellKnownName
Expression getWellKnownName()
Returns the expression whose value will indicate the symbol to draw. The WellKnownName element gives the well-known name of the shape of the mark. Allowed values include at least “square”, “circle”, “triangle”, “star”, “cross”, and “x”, though map servers may draw a different symbol instead if they don't have a shape for all of these. The default WellKnownName is “square”. Renderings of these marks may be made solid or hollow depending on Fill and Stroke elements.if the WellKnowname is null, check the ExternalMark before using the default square symbol.
Both WellKnowName and ExternalMark canot be set, but both can be null. If none are set then the default square symbol is used.
- Returns:
- Expression or null
-
setFill
void setFill(Fill fill)
This parameter defines which fill style to use when rendering the Mark.- Parameters:
fill
- the Fill definition to use when rendering the Mark.
-
getExternalMark
ExternalMark getExternalMark()
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.
- Returns:
- ExternalMark or null
-
setStroke
void setStroke(Stroke stroke)
This paramterer defines which stroke style should be used when rendering the Mark.- Parameters:
stroke
- The Stroke definition to use when rendering the Mark.
-
getFill
Fill getFill()
Returns the object that indicates how the mark should be filled. Null means no fill.- Returns:
- Fill or null
-
setWellKnownName
void setWellKnownName(Expression wellKnownName)
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.- Parameters:
wellKnownName
- The well-known name of a shape. The default value is "square".
-
getStroke
Stroke getStroke()
Returns the object that indicates how the edges of the mark will be drawn. Null means that the edges will not be drawn at all.- Returns:
- stroke or null
-
accept
void accept(StyleVisitor visitor)
calls the visit method of a StyleVisitor- Specified by:
accept
in interfaceGraphicalSymbol
- Specified by:
accept
in interfaceSymbol
- Parameters:
visitor
- the style visitor
-
accept
Object accept(TraversingStyleVisitor visitor, Object data)
-
setExternalMark
void setExternalMark(ExternalMark externalMark)
Mark defined by an external resource.- Parameters:
externalMark
- Indicate an mark defined by an external resource
-
-