Package com.sothawo.mapjfx
Class MapCoordinateElement
- java.lang.Object
-
- com.sothawo.mapjfx.MapElement
-
- com.sothawo.mapjfx.MapCoordinateElement
-
public abstract class MapCoordinateElement extends MapElement
Common base class for elements on the map that have a defined position on the map.- Author:
- P.J. Meisch ([email protected]).
-
-
Field Summary
Fields Modifier and Type Field Description protected javafx.beans.property.SimpleStringProperty
cssClass
custom css style name.protected int
offsetX
horizontal offsetprotected int
offsetY
the vertical offsetprotected javafx.beans.property.SimpleObjectProperty<Coordinate>
position
the coordinate-
Fields inherited from class com.sothawo.mapjfx.MapElement
visible
-
-
Constructor Summary
Constructors Constructor Description MapCoordinateElement()
MapCoordinateElement(int offsetX, int offsetY)
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description javafx.beans.property.SimpleStringProperty
cssClassProperty()
java.lang.String
getCssClass()
abstract java.lang.String
getId()
int
getOffsetX()
int
getOffsetY()
Coordinate
getPosition()
javafx.beans.property.SimpleObjectProperty<Coordinate>
positionProperty()
MapCoordinateElement
setCssClass(java.lang.String cssClass)
sets the cssClass for the LabelMapCoordinateElement
setPosition(Coordinate position)
sets the marker's new positionjava.lang.String
toString()
-
Methods inherited from class com.sothawo.mapjfx.MapElement
getVisible, setVisible, visibleProperty
-
-
-
-
Field Detail
-
position
protected final javafx.beans.property.SimpleObjectProperty<Coordinate> position
the coordinate
-
offsetX
protected final int offsetX
horizontal offset
-
offsetY
protected final int offsetY
the vertical offset
-
cssClass
protected javafx.beans.property.SimpleStringProperty cssClass
custom css style name.
-
-
Method Detail
-
getOffsetX
public int getOffsetX()
-
getOffsetY
public int getOffsetY()
-
getCssClass
public java.lang.String getCssClass()
-
setCssClass
public MapCoordinateElement setCssClass(java.lang.String cssClass)
sets the cssClass for the Label- Parameters:
cssClass
- class name- Returns:
- this object
-
cssClassProperty
public javafx.beans.property.SimpleStringProperty cssClassProperty()
-
getId
public abstract java.lang.String getId()
- Returns:
- the marker's id
-
toString
public java.lang.String toString()
- Overrides:
toString
in classMapElement
-
getPosition
public Coordinate getPosition()
-
positionProperty
public javafx.beans.property.SimpleObjectProperty<Coordinate> positionProperty()
-
setPosition
public MapCoordinateElement setPosition(Coordinate position)
sets the marker's new position- Parameters:
position
- new position- Returns:
- this object
-
-