Class TLcyDrawingStyleRepository

java.lang.Object
com.luciad.lucy.addons.drawing.model.TLcyDrawingStyleRepository

public class TLcyDrawingStyleRepository extends Object

A repository for SLD styles to contain styles which are permanently available. Hence, the styles in this repository are created, stored and restored, even when there is no domain object which actually uses the style.

ILcyDrawingStyleRepositoryListeners can be registered to this class. These listeners are notified when a style from the repository is added, removed or changed.

Since:
8.2
See Also:
  • Constructor Details

    • TLcyDrawingStyleRepository

      public TLcyDrawingStyleRepository()
      Default constructor.
  • Method Details

    • addDrawingStyleRepositoryListener

      public void addDrawingStyleRepositoryListener(ILcyDrawingStyleRepositoryListener aListener)
      Adds the given listener to the list of listeners, so that it will receive change events. These change events occur when a style is added to or removed from the repository, or when a style from the repository is changed.
      Parameters:
      aListener - The listener to add.
    • removeDrawingStyleRepositoryListener

      public void removeDrawingStyleRepositoryListener(ILcyDrawingStyleRepositoryListener aListener)
      Removes the given listener so that it no longer receives change events.
      Parameters:
      aListener - The listener to remove.
    • addStyle

      public void addStyle(Object aStyle)
      Add a style to this repository
      Parameters:
      aStyle - the style to be added
    • removeStyle

      public boolean removeStyle(Object aStyle)
      Remove a style from this repository
      Parameters:
      aStyle - the style to be removed
      Returns:
      true if this repository containted the style aStyle
    • styleChanged

      public void styleChanged(Object aStyle)
      Notify that a style object has changed.
      Parameters:
      aStyle - The style that has changed.
    • getStyleCount

      public int getStyleCount()
      Returns the number of styles in this repository
      Returns:
      the number of styles in this repository
    • getStyle

      public Object getStyle(int aIndex)
      Retrieve the style at index aIndex
      Parameters:
      aIndex - the index of the searched style
      Returns:
      the style at index aIndex in this repository