public class PointLabelPositioner extends AbstractStyle
AbstractStyle.RegisterPersistence
Modifier and Type | Field and Description |
---|---|
static byte |
FORBIDDEN |
static String |
POINT_LABEL_POSITIONER_PERSISTENCE_NAME |
static byte |
PREFERENCE_HIGH |
static byte |
PREFERENCE_LOW |
static byte |
PREFERENCE_NORMAL |
STYLE_PERSISTENCE_DEFINITION_NAME
Constructor and Description |
---|
PointLabelPositioner()
Constructor method
|
PointLabelPositioner(int[] preferenceVector,
String description)
Constructor method
|
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.
|
int[] |
getPreferenceVector() |
boolean |
isSuitableFor(ISymbol sym)
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.
|
static void |
registerPersistent() |
void |
saveToState(PersistentState state)
Saves the internal state of the object on the provided
PersistentState object.
|
getDescription, setDescription
public static final String POINT_LABEL_POSITIONER_PERSISTENCE_NAME
public static final byte FORBIDDEN
public static final byte PREFERENCE_HIGH
public static final byte PREFERENCE_NORMAL
public static final byte PREFERENCE_LOW
public PointLabelPositioner()
public PointLabelPositioner(int[] preferenceVector, String description)
preferenceVector
- description
- public void drawInsideRectangle(Graphics2D g, Rectangle r)
IStyle
g
- Graphics2Dr
- Rectanglepublic boolean isSuitableFor(ISymbol sym)
IStyle
sym
- ISymbolpublic 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
public static void registerPersistent()
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 drawOutline(Graphics2D g, Rectangle r)
IStyle
public int[] getPreferenceVector()