Interface ILspSnappable
- All Known Implementing Classes:
TLspGXYLayerAdapter
,TLspGXYLayerTreeNodeAdapter
,TLspLayer
,TLspLayerTreeNode
public interface ILspSnappable
Determines whether the implementing object can be snapped to during edit operations.
When an object is
ILspSnappable
, the isSnapTarget()
method
determines whether it should be regarded as a source for snapping points or not.
Note that the creation of snapping candidates is separate from this interface. This
interface is merely used to toggle whether snapping should be applied or not for
the implementing object.
The most common implementer of this interface is
TLspLayer
.- Since:
- 2012.0
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionvoid
addPropertyChangeListener
(PropertyChangeListener aPropertyChangeListener) Adds a property change listener to thisILspSnappable
.boolean
Determines whether this object should be regarded as a source for snapping points.void
removePropertyChangeListener
(PropertyChangeListener aPropertyChangeListener) Removes the given property change listener from thisILspSnappable
.void
setSnapTarget
(boolean aIsSnapTarget) Sets whether this object should be regarded as a source for snapping points.
-
Method Details
-
isSnapTarget
boolean isSnapTarget()Determines whether this object should be regarded as a source for snapping points.- Returns:
- true if this object should be regarded as a source for snapping points; false otherwise.
-
setSnapTarget
void setSnapTarget(boolean aIsSnapTarget) Sets whether this object should be regarded as a source for snapping points.- Parameters:
aIsSnapTarget
- if true, this object should be regarded as a source for snapping points, i.e. it should be possible to snap to this object; if false, this object should not produce snapping candidates.
-
addPropertyChangeListener
Adds a property change listener to thisILspSnappable
.- Parameters:
aPropertyChangeListener
- the given property change listener.
-
removePropertyChangeListener
Removes the given property change listener from thisILspSnappable
.- Parameters:
aPropertyChangeListener
- the given property change listener.
-