public abstract class ALcdSLDRulePainter extends Object implements ILcdGXYPainter, ILcdGXYLabelPainter, Cloneable
BODY, CREATING, DEFAULT, HANDLES, RESHAPING, SELECTED, SNAPS, TRANSLATING
DEFAULT, SELECTED
Modifier | Constructor and Description |
---|---|
protected |
ALcdSLDRulePainter(boolean aHasElseFilter,
ALcdSLDSymbolizerPainter[] aSymbolizerPainters)
Creates a rule painter with the given array of symbolizer painters.
|
protected |
ALcdSLDRulePainter(ILcdFilter aFilterEvaluator,
ALcdSLDSymbolizerPainter[] aSymbolizerPainters)
Creates a rule painter with the given filter evaluator and an array of symbolizer painters.
|
Modifier and Type | Method and Description |
---|---|
boolean |
accept(Object aObject)
Accepts an object when either:
it passes the filter evaluator, or
the filter evaluator is null, or
the corresponding rule has an else filter.
|
Object |
clone()
Calls clone of the super class and makes a deep clone of the collection of symbolizer painters.
|
double |
getMaxScaleDenominator()
Returns the max scale denominator of the rule this painter is applied for.
|
double |
getMinScaleDenominator()
Returns the min scale denominator of the rule this painter is applied for.
|
ALcdSLDSymbolizerPainter |
getSymbolizerPainter(int aSymbolizerPainterIndex)
Returns the painter corresponding to the symbolizer at the given index in the rule this painter implements.
|
int |
getSymbolizerPainterCount()
Returns the number of painter for the symbolizers of the rule this painter implements.
|
boolean |
hasElseFilter()
Returns whether the rule that this painter implements had an else filter.
|
abstract boolean |
isScaleValid(ILcdGXYView aView)
Shall return whether the scale of the supplied ILcdGXYView is within the scale range of this rule painter.
|
abstract void |
paint(Graphics aGraphics,
int aPainterMode,
ILcdGXYContext aGXYContext)
Shall perform scale range tests and SLD rule filter tests to decide whether
the object needs to be painted.
|
abstract void |
paintLabel(Graphics aGraphics,
int aLabelPainterMode,
ILcdGXYContext aILcdGXYContext)
Shall perform scale range tests and SLD rule filter tests to decide whether
the object needs to be painted.
|
void |
setMaxScaleDenominator(double aMaxScaleDenominator) |
void |
setMinScaleDenominator(double aMinScaleDenominator) |
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
anchorPointSFCT, boundsSFCT, getCursor, getDisplayName, getObject, isTouched, setObject, snapTarget, supportSnap
addPropertyChangeListener, removePropertyChangeListener
getLocationIndex, getObject, getPossibleLocationCount, labelBoundsSFCT, setLocationIndex, setObject
protected ALcdSLDRulePainter(ILcdFilter aFilterEvaluator, ALcdSLDSymbolizerPainter[] aSymbolizerPainters)
aFilterEvaluator
- evaluates objects passed to this painter to check whether they comply
to this rule.aSymbolizerPainters
- a collection of symbolizer painters implementing the style that was defined
in the symbolizers for the rule this painter is created for.protected ALcdSLDRulePainter(boolean aHasElseFilter, ALcdSLDSymbolizerPainter[] aSymbolizerPainters)
aHasElseFilter
- indicates whether this rule had an else filter.aSymbolizerPainters
- a collection of symbolizer painters implementing the style that was defined
in the symbolizers for the rule this painter is created for.public boolean hasElseFilter()
public ALcdSLDSymbolizerPainter getSymbolizerPainter(int aSymbolizerPainterIndex)
aSymbolizerPainterIndex
- the index of the symbolizer to retrieve a painter for.public int getSymbolizerPainterCount()
public abstract boolean isScaleValid(ILcdGXYView aView)
aView
- public abstract void paint(Graphics aGraphics, int aPainterMode, ILcdGXYContext aGXYContext)
paint
in interface ILcdGXYPainter
aGraphics
- the Graphics on which the representation of the object is paintedaPainterMode
- the mode the object is represented in (see class documentation).aGXYContext
- the ILcdGXYContext
the drawing depends on.public abstract void paintLabel(Graphics aGraphics, int aLabelPainterMode, ILcdGXYContext aILcdGXYContext)
paintLabel
in interface ILcdGXYLabelPainter
aGraphics
- the Graphics
instance on which to paint.aLabelPainterMode
- a combination of ILcdGXYLabelPainter.DEFAULT and ILcdGXYLabelPainter.SELECTED.aILcdGXYContext
- the ILcdGXYContext
in which the label painting has to be
performed.ILcdGXYLabelPainter.DEFAULT
,
ILcdGXYLabelPainter.SELECTED
public Object clone()
clone
in interface ILcdCloneable
clone
in interface ILcdGXYLabelPainter
clone
in class Object
Object.clone()
public boolean accept(Object aObject)
aObject
- the object to check.public double getMinScaleDenominator()
public double getMaxScaleDenominator()
public void setMinScaleDenominator(double aMinScaleDenominator)
public void setMaxScaleDenominator(double aMaxScaleDenominator)