public class SimpleLineSymbol extends AbstractLineSymbol implements ISimpleLineSymbol
Modifier and Type | Class and Description |
---|---|
static class |
SimpleLineSymbol.RegisterPersistence |
static class |
SimpleLineSymbol.RegisterSymbol |
Modifier and Type | Field and Description |
---|---|
static String |
SIMPLE_LINE_SYMBOL_PERSISTENCE_DEFINITION_NAME |
LINE_SYMBOL_PERSISTENCE_DEFINITION_NAME
SYMBOL_PERSISTENCE_DEFINITION_NAME
SYMBOL_NAME
SELECTION_COLOR
PAPER, WORLD
Constructor and Description |
---|
SimpleLineSymbol() |
Modifier and Type | Method and Description |
---|---|
Object |
clone()
Creates a copy of the object.
|
void |
draw(Graphics2D g,
AffineTransform affineTransform,
Geometry geom,
Feature feature,
Cancellable cancel)
Used when a symbol is going to be drawn.The method to do
it will depend on the derived version of the symbol.
|
void |
drawInsideRectangle(Graphics2D g,
AffineTransform scaleInstance,
Rectangle r,
PrintAttributes properties)
Useful to render the symbol inside the TOC, or inside little
rectangles.
|
double |
getLineWidth()
Returns the width of the line symbol
|
int |
getOnePointRgb()
Returns the rgb of the symbol when it is drawn like a point.
|
ISymbol |
getSymbolForSelection()
Returns the derived version of the symbol that will be used to draw the
feature when it is selected.
|
void |
loadFromState(PersistentState state)
Set the state of the object from the state passed as parameter.
|
void |
saveToState(PersistentState state)
Saves the internal state of the object on the provided
PersistentState object.
|
void |
setLineWidth(double width)
Sets the width of the line symbol.
|
getAlpha, getCartographicSize, getColor, getLineStyle, getPixExtentPlus, getSymbolType, isSuitableFor, offsetFShape, print, setAlpha, setCartographicSize, setColor, setLineColor, setLineStyle, toCartographicSize
cloneForSelection, equals, getDescription, getID, getReferenceSystem, getUnit, isOneDotOrPixel, isShapeVisible, setDescription, setID, setIsShapeVisible, setReferenceSystem, setUnit
finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getAlpha, getColor, getLineStyle, setAlpha, setLineColor, setLineStyle
getDescription, getPixExtentPlus, getSymbolType, isOneDotOrPixel, isShapeVisible, isSuitableFor, setColor, setDescription
print
getCartographicSize, getReferenceSystem, getUnit, setCartographicSize, setReferenceSystem, setUnit, toCartographicSize
public static final String SIMPLE_LINE_SYMBOL_PERSISTENCE_DEFINITION_NAME
public ISymbol getSymbolForSelection()
ISymbol
getSymbolForSelection
in interface ISymbol
public void draw(Graphics2D g, AffineTransform affineTransform, Geometry geom, Feature feature, Cancellable cancel)
ISymbol
public int getOnePointRgb()
ISymbol
getOnePointRgb
in interface ISymbol
getOnePointRgb
in class AbstractLineSymbol
public void drawInsideRectangle(Graphics2D g, AffineTransform scaleInstance, Rectangle r, PrintAttributes properties) throws SymbolDrawingException
ISymbol
drawInsideRectangle
in interface ISymbol
drawInsideRectangle
in class AbstractLineSymbol
properties
- TODOSymbolDrawingException
- TODOpublic void setLineWidth(double width)
ILineSymbol
setLineWidth
in interface ILineSymbol
public double getLineWidth()
ILineSymbol
getLineWidth
in interface ILineSymbol
public Object clone() throws CloneNotSupportedException
Cloneable
clone
in class AbstractLineSymbol
CloneNotSupportedException
- if the instance of the object cannot
be cloned. As this is extending Cloneable
so
its sure it implements it, so this exception may be used for problems
on specific object instances.Object#clone()}.
public void loadFromState(PersistentState state) throws PersistenceException
Persistent
loadFromState
in interface Persistent
loadFromState
in class AbstractLineSymbol
PersistenceException
public void saveToState(PersistentState state) throws PersistenceException
Persistent
saveToState
in interface Persistent
saveToState
in class AbstractLineSymbol
PersistenceException