public class DefaultMask extends AbstractStyle implements IMask
Modifier and Type | Class and Description |
---|---|
static class |
DefaultMask.RegisterPersistence |
Modifier and Type | Field and Description |
---|---|
static String |
DEFAULT_MASK_PERSISTENCE_DEFINITION_NAME |
STYLE_PERSISTENCE_DEFINITION_NAME
Constructor and Description |
---|
DefaultMask() |
Modifier and Type | Method and Description |
---|---|
Object |
clone()
Creates a copy of the object.
|
void |
drawInsideRectangle(Graphics2D g,
Rectangle r)
Useful to render the symbol inside the TOC, or inside little
rectangles.
|
void |
drawOutline(Graphics2D g,
Rectangle r)
Used to show an outline of the style to graphically show its properties.
|
IFillSymbol |
getFillSymbol() |
Geometry |
getHaloShape(Shape shp) |
double |
getSize() |
boolean |
isSuitableFor(ISymbol symbol)
True if this symbol is ok for the style or class.
|
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 |
setFillSymbol(IFillSymbol fill) |
void |
setSize(double size) |
getDescription, setDescription
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getDescription, setDescription
public static final String DEFAULT_MASK_PERSISTENCE_DEFINITION_NAME
public IFillSymbol getFillSymbol()
getFillSymbol
in interface IMask
public void setFillSymbol(IFillSymbol fill)
setFillSymbol
in interface IMask
public void drawInsideRectangle(Graphics2D g, Rectangle r)
IStyle
drawInsideRectangle
in interface IStyle
g
- Graphics2Dr
- Rectanglepublic Geometry getHaloShape(Shape shp)
getHaloShape
in interface IMask
public boolean isSuitableFor(ISymbol symbol)
IStyle
isSuitableFor
in interface IStyle
symbol
- ISymbolpublic void drawOutline(Graphics2D g, Rectangle r)
IStyle
drawOutline
in interface IStyle
public Object clone() throws CloneNotSupportedException
Cloneable
clone
in class AbstractStyle
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 AbstractStyle
PersistenceException
public void saveToState(PersistentState state) throws PersistenceException
Persistent
saveToState
in interface Persistent
saveToState
in class AbstractStyle
PersistenceException