Package org.geotools.renderer.lite
Class MetaBufferEstimator
Object
DefaultFilterVisitor
FilterAttributeExtractor
MetaBufferEstimator
- All Implemented Interfaces:
ExpressionVisitor,FilterVisitor,StyleVisitor
Parses a style or part of it and returns the size of the largest stroke and the biggest point symbolizer whose width
is specified with a literal expression.
Also provides an indication whether the stroke width is accurate, or if a non literal width has been found.
Also provides an indication whether the stroke width is accurate, or if a non literal width has been found.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected FilterAttributeExtractorprotected intprotected booleanprotected static final LoggerThe logger for the rendering module.Fields inherited from class FilterAttributeExtractor
attributeNames, featureType, propertyNames, usingDynamicProperties, usingVolatileFunctions -
Constructor Summary
ConstructorsConstructorDescriptionBuilds an estimator suitable for styles without expressionsMetaBufferEstimator(Feature sample) Builds an estimator suitable for styles with expression, will evaluate against the provided feature -
Method Summary
Modifier and TypeMethodDescriptionprotected voidevaluateWidth(Expression width) intprotected doublegetDouble(Expression ex) protected intprotected booleanisConstant(Expression ex) booleanprotected booleanisNull(Expression exp) voidreset()Should you reuse this extractor multiple time, calling this method will reset the buffer and flagsvoidvisit(AnchorPoint ap) Called when accept is called on an anchor pointvoidCalled when accept is called on a rasterChannelSelectionelementvoidCalled when accept is called on a raster color mapvoidvisit(ColorMapEntry entry) Called when accept is called on a raster color map entryvoidvisit(ContrastEnhancement contrastEnhancement) Called when accept is called on a raster ContrastEnhancement elementvoidvisit(Displacement dis) Called when accept is called on a displacementvoidvisit(ExternalGraphic exgr) Called when accept is called on an external graphicvoidCalled when accept is called on a FeatureTypeConstraint.voidvisit(FeatureTypeStyle fts) Called when accept is called on a fetauretypestylevoidCalled when accept is called on a fillvoidCalled when accept is called on a graphicvoidCalled when accept is called on a halovoidvisit(ImageOutline outline) Called when accept is called on a rasterImageOutlineelementvoidvisit(LinePlacement lp) Called when accept is called on a Line Placementvoidvisit(LineSymbolizer line) Called when accept is called on a linesymbolizervoidCalled when accept is called on a markvoidvisit(NamedLayer layer) Called when accept is called on a NamedLayer.voidvisit(OverlapBehavior ob) Called when accept is called on a rasterOverlapBehaviorEnumelementvoidvisit(PointPlacement pp) Called when accept is called on a Point Placementvoidvisit(PointSymbolizer ps) Called when accept is called on a pointsymbolizervoidvisit(PolygonSymbolizer poly) Called when accept is called on a polygon symbolizervoidCalled when accept is called on a rastersymbolizervoidCalled when accept is called on a rulevoidvisit(SelectedChannelType sct) Called when accept is called on a rasterSelectedChannelTypeelementvoidvisit(ShadedRelief sr) Called when accept is called on a rasterShadedReliefelementvoidCalled when accept is called on a strokevoidCalled when accept is called on a Style.voidCalled when accept is called on a StyledLayerDescriptor.voidvisit(Symbolizer sym) since it is impossible to create a Symbolizer this method should generate an exception or warning.voidvisit(TextSymbolizer text) Called when accept is called on a textsymbolizervoidCalled when accept is called on a UserLayer.Methods inherited from class FilterAttributeExtractor
clear, getAttributeNames, getAttributeNameSet, getPropertyNameSet, isConstantExpression, isUsingDynamincProperties, visit, visitMethods inherited from class DefaultFilterVisitor
visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visitNullFilter
-
Field Details
-
LOGGER
The logger for the rendering module. -
attributeExtractor
-
estimateAccurate
protected boolean estimateAccurate- UML property:
- name="estimateAccurate"
-
buffer
protected int buffer- UML property:
- name="buffer"
-
-
Constructor Details
-
MetaBufferEstimator
public MetaBufferEstimator()Builds an estimator suitable for styles without expressions -
MetaBufferEstimator
Builds an estimator suitable for styles with expression, will evaluate against the provided feature
-
-
Method Details
-
reset
public void reset()Should you reuse this extractor multiple time, calling this method will reset the buffer and flags -
getBuffer
public int getBuffer()- UML property:
- name="buffer"
-
isEstimateAccurate
public boolean isEstimateAccurate()- UML property:
- name="estimateAccurate"
-
visit
Description copied from interface:StyleVisitorCalled when accept is called on a Style.- Specified by:
visitin interfaceStyleVisitor- Parameters:
style- The style to visit
-
visit
Description copied from interface:StyleVisitorCalled when accept is called on a rule- Specified by:
visitin interfaceStyleVisitor- Parameters:
rule- the rule to visit
-
visit
Description copied from interface:StyleVisitorCalled when accept is called on a fetauretypestyle- Specified by:
visitin interfaceStyleVisitor- Parameters:
fts- the feature type styler to visit
-
visit
Description copied from interface:StyleVisitorCalled when accept is called on a fill- Specified by:
visitin interfaceStyleVisitor- Parameters:
fill- the fill to be visited
-
visit
Description copied from interface:StyleVisitorCalled when accept is called on a stroke- Specified by:
visitin interfaceStyleVisitor- Parameters:
stroke- the stroke to visit- See Also:
-
isNull
-
visit
Description copied from interface:StyleVisitorsince it is impossible to create a Symbolizer this method should generate an exception or warning.- Specified by:
visitin interfaceStyleVisitor- Parameters:
sym- the symbolizer to visit- See Also:
-
visit
Description copied from interface:StyleVisitorCalled when accept is called on a rastersymbolizer- Specified by:
visitin interfaceStyleVisitor- Parameters:
rs- the raster symbolizer to visit
-
visit
Description copied from interface:StyleVisitorCalled when accept is called on a pointsymbolizer- Specified by:
visitin interfaceStyleVisitor- Parameters:
ps- the point symbolizer to visit- See Also:
-
visit
Description copied from interface:StyleVisitorCalled when accept is called on a linesymbolizer- Specified by:
visitin interfaceStyleVisitor- Parameters:
line- the line symbolizer to visit- See Also:
-
visit
Description copied from interface:StyleVisitorCalled when accept is called on a polygon symbolizer- Specified by:
visitin interfaceStyleVisitor- Parameters:
poly- the polygon symbolizer to visit- See Also:
-
visit
Description copied from interface:StyleVisitorCalled when accept is called on a textsymbolizer- Specified by:
visitin interfaceStyleVisitor- Parameters:
text- the text symbolizer to visit- See Also:
-
visit
Description copied from interface:StyleVisitorCalled when accept is called on a graphic- Specified by:
visitin interfaceStyleVisitor- Parameters:
gr- the graphic to visit- See Also:
-
evaluateWidth
-
getPositiveValue
-
getDouble
-
isConstant
-
visit
Description copied from interface:StyleVisitorCalled when accept is called on a mark- Specified by:
visitin interfaceStyleVisitor- Parameters:
mark- the mark to visit- See Also:
-
visit
Description copied from interface:StyleVisitorCalled when accept is called on an external graphic- Specified by:
visitin interfaceStyleVisitor- Parameters:
exgr- the external graphic to visit- See Also:
-
visit
Description copied from interface:StyleVisitorCalled when accept is called on a Point Placement- Specified by:
visitin interfaceStyleVisitor- Parameters:
pp- the point placement to visit- See Also:
-
visit
Description copied from interface:StyleVisitorCalled when accept is called on an anchor point- Specified by:
visitin interfaceStyleVisitor- Parameters:
ap- the anchor point to visit- See Also:
-
visit
Description copied from interface:StyleVisitorCalled when accept is called on a displacement- Specified by:
visitin interfaceStyleVisitor- Parameters:
dis- the displacement to visit- See Also:
-
visit
Description copied from interface:StyleVisitorCalled when accept is called on a Line Placement- Specified by:
visitin interfaceStyleVisitor- Parameters:
lp- the line placement to visit- See Also:
-
visit
Description copied from interface:StyleVisitorCalled when accept is called on a halo- Specified by:
visitin interfaceStyleVisitor- Parameters:
halo- the halo to visit- See Also:
-
visit
Description copied from interface:StyleVisitorCalled when accept is called on a StyledLayerDescriptor.- Specified by:
visitin interfaceStyleVisitor- Parameters:
sld- The StyledLayerDescriptor to visit
-
visit
Description copied from interface:StyleVisitorCalled when accept is called on a NamedLayer.- Specified by:
visitin interfaceStyleVisitor- Parameters:
layer- The NamedLayer to visit
-
visit
Description copied from interface:StyleVisitorCalled when accept is called on a UserLayer.- Specified by:
visitin interfaceStyleVisitor- Parameters:
layer- The UserLayer to visit
-
visit
Description copied from interface:StyleVisitorCalled when accept is called on a FeatureTypeConstraint.- Specified by:
visitin interfaceStyleVisitor- Parameters:
ftc- The FeatureTypeConstraint to visit
-
visit
Description copied from interface:StyleVisitorCalled when accept is called on a raster color map- Specified by:
visitin interfaceStyleVisitor- Parameters:
map- the color map to visit
-
visit
Description copied from interface:StyleVisitorCalled when accept is called on a raster color map entry- Specified by:
visitin interfaceStyleVisitor- Parameters:
entry- the color map to visit
-
visit
Description copied from interface:StyleVisitorCalled when accept is called on a raster ContrastEnhancement element- Specified by:
visitin interfaceStyleVisitor- Parameters:
contrastEnhancement- theContrastEnhancementto visit.
-
visit
Description copied from interface:StyleVisitorCalled when accept is called on a rasterImageOutlineelement- Specified by:
visitin interfaceStyleVisitor- Parameters:
outline- theImageOutlineto visit.
-
visit
Description copied from interface:StyleVisitorCalled when accept is called on a rasterChannelSelectionelement- Specified by:
visitin interfaceStyleVisitor- Parameters:
cs- theChannelSelectionto visit.
-
visit
Description copied from interface:StyleVisitorCalled when accept is called on a rasterOverlapBehaviorEnumelement- Specified by:
visitin interfaceStyleVisitor- Parameters:
ob- theOverlapBehaviorEnumto visit.
-
visit
Description copied from interface:StyleVisitorCalled when accept is called on a rasterSelectedChannelTypeelement- Specified by:
visitin interfaceStyleVisitor- Parameters:
sct- theSelectedChannelTypeto visit.
-
visit
Description copied from interface:StyleVisitorCalled when accept is called on a rasterShadedReliefelement- Specified by:
visitin interfaceStyleVisitor- Parameters:
sr- theShadedReliefto visit.
-