Class ALspLabelLocation

java.lang.Object
com.luciad.view.lightspeed.label.location.ALspLabelLocation
All Implemented Interfaces:
ILcdCloneable, Cloneable
Direct Known Subclasses:
ALspStampLabelLocation, TLspPathLabelLocation

public abstract class ALspLabelLocation extends Object implements ILcdCloneable

Instances of this class contain the location information about a specific label. It is used as the data transfer object between ALspLabelLocations and the various parties that need to know the location of a label.

This class can be sub-classed if you want to add properties about the location of a label.

Note: When creating an extension of this class, also overwrite the copyFrom and clone method to make sure your extra properties are copied.

Since:
2012.0
  • Constructor Details

    • ALspLabelLocation

      public ALspLabelLocation()
  • Method Details

    • isEditedByEditor

      public boolean isEditedByEditor()
      Checks if this location was created or edited by an editor.
      Returns:
      if this location was created or edited by an editor.
      See Also:
    • setEditedByEditor

      public void setEditedByEditor(boolean aEdited)
      Marks this location as edited by an editor.
      Parameters:
      aEdited - true to mark this location as edited by an editor.
      See Also:
    • isEditedByPlacer

      public boolean isEditedByPlacer()
      Returns if this location was created or edited by a label placer.
      Returns:
      if this location was created or edited by a label placer.
      See Also:
    • setEditedByPlacer

      public void setEditedByPlacer(boolean aEdited)
      Marks this location as edited by a placer.
      Parameters:
      aEdited - true to mark this location as edited by a placer.
      See Also:
    • isSticky

      public boolean isSticky()
      Returns if this label is sticky. If a label editor or label placer sets a label location to sticky, it means that no other label placer or editor should modify the label.
      Returns:
      if this label is sticky.
      See Also:
    • setSticky

      public void setSticky(boolean aSticky)
      Sets if this location is sticky.
      Parameters:
      aSticky - true to make this location sticky.
      See Also:
    • copyFrom

      public void copyFrom(ALspLabelLocation aLabelLocation)

      Copies the location settings from the given label location.

      When creating an extension of this class, also overwrite this method to make sure your extra properties are copied.

      Parameters:
      aLabelLocation - the label location to copy properties from.
    • clone

      public ALspLabelLocation clone()
      Description copied from interface: ILcdCloneable

      Makes Object.clone() public.

      When for example extending from java.lang.Object, it can be implemented like this:
      
       public Object clone() {
         try {
           return super.clone();
         } catch ( CloneNotSupportedException e ) {
           // Cannot happen: extends from Object and implements Cloneable (see also Object.clone)
           throw new RuntimeException( e );
         }
       }
       
      Specified by:
      clone in interface ILcdCloneable
      Overrides:
      clone in class Object
      See Also:
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object