Class TLcdMS2525bObjectIconProvider

java.lang.Object
com.luciad.symbology.milstd2525b.view.TLcdMS2525bObjectIconProvider
All Implemented Interfaces:
ILcdObjectIconProvider

public class TLcdMS2525bObjectIconProvider extends Object implements ILcdObjectIconProvider
Icon provider for ILcdMS2525bCoded objects. When an object also implements ILcdStyledMilitarySymbol, its style will be associated with the icon. Otherwise, a default style will be used. This default style can be customized using the methods getDefaultMilitarySymbolStyle() and setDefaultMilitarySymbolStyle(TLcdMilitarySymbolStyle).

The icons generated by this ILcdObjectIconProvider are cached using a simple LRU cache. The default maximum cache size is 5000 icons. If you wish to adjust the max cache size, you can do this using the following property: com.luciad.symbology.iconsymbols.MAX_CACHE_SIZE

  • Constructor Details

    • TLcdMS2525bObjectIconProvider

      public TLcdMS2525bObjectIconProvider()
  • Method Details

    • setDefaultStyle

      @Deprecated public void setDefaultStyle(ILcdMS2525bStyle aDefaultStyle)
      Sets a default ILcdMS2525bStyle instance that is used for objects which don't implement ILcdMS2525bStyle.
      Parameters:
      aDefaultStyle - A ILcdMS2525bStyle instance.
    • getDefaultStyle

      @Deprecated public ILcdMS2525bStyle getDefaultStyle()
      Deprecated.
      Returns the default ILcdMS2525bStyle instance that is used for objects which don't implement ILcdMS2525bStyle.
      Returns:
      the default ILcdMS2525bStyle instance that is used for objects which don't implement ILcdMS2525bStyle.
    • setDefaultMilitarySymbolStyle

      public void setDefaultMilitarySymbolStyle(TLcdMilitarySymbolStyle aDefaultStyle)
      Sets a default TLcdMilitarySymbolStyle instance that is used for objects which don't implement ILcdStyledMilitarySymbol.
      Parameters:
      aDefaultStyle - A TLcdMilitarySymbolStyle instance. Never null.
      Throws:
      NullPointerException - If the given TLcdMilitarySymbolStyle is null.
      Since:
      2024.0
    • getDefaultMilitarySymbolStyle

      public TLcdMilitarySymbolStyle getDefaultMilitarySymbolStyle()
      Returns the default TLcdMilitarySymbolStyle that is used for objects which don't implement ILcdStyledMilitarySymbol.
      Returns:
      the default TLcdMilitarySymbolStyle that is used for objects which don't implement ILcdStyledMilitarySymbol.
      Since:
      2024.0
    • setIconSize

      @Deprecated public void setIconSize(int aSize)
      Deprecated.
      Replaced by the more general method setDefaultStyle(ILcdMS2525bStyle).
      Sets the default icon size that is used for objects that don't implement ILcdMS2525bStyled..
      Parameters:
      aSize - the default icon size.
    • getIconSize

      @Deprecated public int getIconSize()
      Deprecated.
      Replaced by the more general method getDefaultStyle().
      Returns the default icon size.
      Returns:
      the default icon size.
    • setOutlined

      @Deprecated public void setOutlined(boolean aIsOutlined)
      Deprecated.
      Replaced by the more general method setDefaultStyle(ILcdMS2525bStyle).
      Sets the default outline property that is used for objects that don't implement ILcdMS2525bStyled.
      Parameters:
      aIsOutlined - the default outline property.
    • getOutlined

      @Deprecated public boolean getOutlined()
      Deprecated.
      Replaced by the more general method getDefaultStyle().
      Returns the default outline property.
      Returns:
      The default outline property.
    • getIcon

      public ILcdIcon getIcon(Object aObject) throws IllegalArgumentException
      Returns an icon for ILcdMS2525bCoded objects. If the given object also implements the ILcdMS2525bStyled interface, its style will be associated with the icon. When this is not the case, a default style will be used. This default style can be customized using the methods getDefaultStyle() and setDefaultStyle(ILcdMS2525bStyle).
      Specified by:
      getIcon in interface ILcdObjectIconProvider
      Parameters:
      aObject - Should be an instance of ILcdMS2525bCoded and optionally also an instance of ILcdMS2525bStyled.
      Returns:
      An ILcdIcon that also implements ILcdAnchoredIcon.
      Throws:
      IllegalArgumentException - if the given object isn't an instance of ILcdMS2525bCoded.
    • canGetIcon

      public boolean canGetIcon(Object aObject)
      Description copied from interface: ILcdObjectIconProvider
      Returns whether an icon can be returned for a given object.
      Specified by:
      canGetIcon in interface ILcdObjectIconProvider
      Parameters:
      aObject - to object to check whether an icon can be provided for it.
      Returns:
      whether an icon can be returned for a given object.