public class PictureMarkerSymbol extends AbstractMarkerSymbol implements IPictureMarkerSymbol
Modifier and Type | Class and Description |
---|---|
static class |
PictureMarkerSymbol.RegisterPersistence |
static class |
PictureMarkerSymbol.RegisterSymbol |
Modifier and Type | Field and Description |
---|---|
static String |
PICTURE_MARKER_SYMBOL_PERSISTENCE_DEFINITION_NAME |
MARKER_SYMBOL_PERSISTENCE_DEFINITION_NAME
SYMBOL_PERSISTENCE_DEFINITION_NAME
CIRCLE_STYLE, CROSS_STYLE, DIAMOND_STYLE, SQUARE_STYLE, STAR_STYLE, SYMBOL_NAME, TRIANGLE_STYLE, VERTICAL_LINE_STYLE, X_STYLE
SELECTION_COLOR
PAPER, WORLD
Constructor and Description |
---|
PictureMarkerSymbol()
Constructor method
|
PictureMarkerSymbol(URL imageURL,
URL selImageURL)
Constructor method
|
Modifier and Type | Method and Description |
---|---|
Object |
clone()
Creates a copy of the object.
|
void |
draw(Graphics2D g,
AffineTransform affineTransform,
Geometry geom,
Feature f,
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.
|
String |
getClassName() |
URL |
getSelectedSource()
Returns the URL of the image that is used as a marker symbol (when it
is selected in the map)
|
URL |
getSource()
Returns the URL of the image that is used as a marker symbol
|
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 |
setImage(URL imageUrl)
Sets the file for the image to be used as a marker symbol
|
void |
setSelImage(URL imageFileUrl)
Sets the file for the image to be used as a marker symbol (when it is
selected in the map)
|
getCartographicSize, getColor, getMask, getOffset, getOnePointRgb, getPixExtentPlus, getRotation, getSize, getSymbolType, isSuitableFor, print, setAlpha, setCartographicSize, setColor, setMask, setOffset, setRotation, setSize, toCartographicSize
cloneForSelection, equals, getDescription, getID, getReferenceSystem, getUnit, isOneDotOrPixel, isShapeVisible, setDescription, setID, setIsShapeVisible, setReferenceSystem, setUnit
finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getColor, getMask, getOffset, getRotation, getSize, setAlpha, setColor, setMask, setOffset, setRotation, setSize
getDescription, getOnePointRgb, getPixExtentPlus, getSymbolType, isOneDotOrPixel, isShapeVisible, isSuitableFor, setDescription
print
getCartographicSize, getReferenceSystem, getUnit, setCartographicSize, setReferenceSystem, setUnit, toCartographicSize
public static final String PICTURE_MARKER_SYMBOL_PERSISTENCE_DEFINITION_NAME
public PictureMarkerSymbol()
public PictureMarkerSymbol(URL imageURL, URL selImageURL) throws IOException
imageURL
- , URL of the normal imageselImageURL
- , URL of the image when it is selected in the mapIOException
public void setImage(URL imageUrl) throws IOException
setImage
in interface IPictureMarkerSymbol
imageFile
- , FileIOException
public void setSelImage(URL imageFileUrl) throws IOException
setSelImage
in interface IPictureMarkerSymbol
imageFile
- , FileIOException
public ISymbol getSymbolForSelection()
ISymbol
getSymbolForSelection
in interface ISymbol
public void draw(Graphics2D g, AffineTransform affineTransform, Geometry geom, Feature f, Cancellable cancel)
ISymbol
public void drawInsideRectangle(Graphics2D g, AffineTransform scaleInstance, Rectangle r, PrintAttributes properties) throws SymbolDrawingException
ISymbol
drawInsideRectangle
in interface ISymbol
drawInsideRectangle
in class AbstractMarkerSymbol
properties
- TODOSymbolDrawingException
- TODOpublic String getClassName()
public URL getSource()
getSource
in interface IPictureMarkerSymbol
public URL getSelectedSource()
getSelectedSource
in interface IPictureMarkerSymbol
public Object clone() throws CloneNotSupportedException
Cloneable
clone
in class AbstractMarkerSymbol
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 AbstractMarkerSymbol
PersistenceException
public void saveToState(PersistentState state) throws PersistenceException
Persistent
saveToState
in interface Persistent
saveToState
in class AbstractMarkerSymbol
PersistenceException