class Symbolizer extends java.lang.Object implements Style, java.lang.Cloneable
A Base class for all Symbolizers. All Symbolizers can have a Filter, min and max scales, and a z-index.
Symbolizer sym = new Fill("white") sym.where(new Filter("name='Washington'")) sym.range(100, 500) sym.zindex(5)
Modifiers | Name | Description |
---|---|---|
protected static FilterFactory |
filterFactory |
The GeoTools FilterFactory |
protected static StyleBuilder |
styleBuilder |
The GeoTools StyleBuilder |
protected static StyleFactoryImpl |
styleFactory |
The GeoTools StyleFactory |
protected Map |
styleOptions |
A Map of FeatureTypeStyle options |
Constructor and description |
---|
Symbolizer
() Create a new Symbolizer |
Type Params | Return Type | Name and description |
---|---|---|
|
Composite |
and(Symbolizer other) Combine this Symbolizer with another. |
|
protected void |
apply(Symbolizer sym) Apply this Symbolizer to the GeoTools Symbolizer |
|
void |
asSLD(java.io.OutputStream out) Write this Symbolizer to an SLD document |
|
void |
asSLD(java.io.File file) Write this Symbolizer to a SLD File |
|
protected java.lang.String |
buildString(java.lang.String name, Map properties) Build a string representation of the Symbolizer |
|
Symbolizer |
composite(Map params, java.lang.String composite) Set composite (copy, destination, source-over, destination-over, source-in, destination-in, source-out, destination-out, source-atop, destination-atop, xor) or blending (multiply, screen, overlay, darken, lighten, color-dodge, color-burn, hard-light, soft-light, difference, exclusion) |
|
protected static Symbolizer |
createGeoToolsSymbolizer(java.lang.Class clazz) Create a GeoTools Symbolizer of the given Class |
|
static Symbolizer |
getDefault(java.lang.String geometryType, java.lang.Object color) Get a default Symbolizer for the given geometry type |
|
static Symbolizer |
getDefault(Map options, java.lang.String geometryType) Get a default Symbolizer for the given geometry type. |
|
protected static java.util.List<GtSymbolizer> |
getGeoToolsSymbolizers(Rule rule, java.lang.Class clazz) Get a List of GeoTools Symbolizers from the Rule of the given Class. |
|
Style |
getGtStyle() Get the GeoTools Style from this Symbolizer |
|
java.lang.String |
getSld() Get this Symbolizer as an SLD String |
|
Composite |
plus(Symbolizer other) Combine this Symbolizer with another. |
|
protected void |
prepare(Rule rule) Prepare the GeoTools Rule by applying this Symbolizer. |
|
protected void |
prepare(FeatureTypeStyle fts, Rule rule) Prepare the GeoTools FeatureTypeStyle and Rule by applying this Symbolizer. |
|
Symbolizer |
range(double min, double max) Apply min/max scale denominator |
|
Symbolizer |
range(Map minMax) Apply min/max scale denominator using keywords. |
|
Symbolizer |
sortBy(java.util.List fields) Set single layer z-ordering |
|
Symbolizer |
sortBy(java.lang.String group, java.util.List fields) Set cross layer z-ordering |
|
Symbolizer |
where(java.lang.Object filter) Apply a filter to the symbolizer. |
|
Symbolizer |
zindex(int z) Apply a z-index. |
Methods inherited from class | Name |
---|---|
class java.lang.Object |
java.lang.Object#wait(long, int), java.lang.Object#wait(long), java.lang.Object#wait(), java.lang.Object#equals(java.lang.Object), java.lang.Object#toString(), java.lang.Object#hashCode(), java.lang.Object#getClass(), java.lang.Object#notify(), java.lang.Object#notifyAll() |
The GeoTools FilterFactory
The GeoTools StyleBuilder
The GeoTools StyleFactory
A Map of FeatureTypeStyle options
The Filter
A Map of Symbolizer options
A List of min and max scales
The z index
Combine this Symbolizer with another.
other
- The other SymbolizerApply this Symbolizer to the GeoTools Symbolizer
sym
- The GeoTools SymbolizerWrite this Symbolizer to an SLD document
out
- The OutputStreamWrite this Symbolizer to a SLD File
file
- The SLD FileBuild a string representation of the Symbolizer
name
- The name of the Symbolizer (Fill, Hatch, Halo, ect...)properties
- A Map of propertiesSet composite (copy, destination, source-over, destination-over, source-in, destination-in, source-out, destination-out, source-atop, destination-atop, xor) or blending (multiply, screen, overlay, darken, lighten, color-dodge, color-burn, hard-light, soft-light, difference, exclusion)
params
- The optional named parameters:
composite
- The composite of blending valueCreate a GeoTools Symbolizer of the given Class
clazz
- The GeoTools Symbolizer ClassGet a default Symbolizer for the given geometry type
geometryType
- The geometry typeGet a default Symbolizer for the given geometry type.
options
- Optional named parameters:
geometryType
- The geometry typeGet a List of GeoTools Symbolizers from the Rule of the given Class. If no Symbolizers of the given Class exist in the Rule, one is created.
rule
- The GeoTools Ruleclazz
- The GeoTools Symbolizer ClassGet the GeoTools Style from this Symbolizer
Get this Symbolizer as an SLD String
Combine this Symbolizer with another.
other
- The other SymbolizerPrepare the GeoTools Rule by applying this Symbolizer.
rule
- The GeoTools RulePrepare the GeoTools FeatureTypeStyle and Rule by applying this Symbolizer.
fts
- The GeoTools FeatureTypeStylerule
- The GeoTools RuleApply min/max scale denominator
min
- The min scale (defaults to -1)max
- The max scale (defaults to -1)Apply min/max scale denominator using keywords.
new Fill('black').range(min: '100', max: '2000')
new Stroke('teal').range(min: '1000')
minMax
- A Map of named parameters (min, max)Set single layer z-ordering @return
fields
- The List of Fields. The items in the List an be a Field, a Map with field and direction (A or D)
keys, or just String with field name and direction.Set cross layer z-ordering
group
- The group namefields
- The List of Fields. The items in the List an be a Field, a Map with field and direction (A or D)
keys, or just String with field name and direction.Apply a filter to the symbolizer. The Filter can be a CQL string or a geoScript.filter.Filter
filter
- A CQL String or a FilterApply a z-index. Symbolizers with higher z-index are drawn on the top of those with smaller z-index
z
- The z-indexGroovy Documentation