java.lang.Object
com.esri.arcgisruntime.ogc.kml.KmlIcon

public final class KmlIcon extends Object
A KML icon.

A KML icon defines the image associated with an overlay or an icon style.

Since:
100.6.0
  • Constructor Details

    • KmlIcon

      public KmlIcon(String uri)
      Constructs a KmlIcon from the given URI.

      The URI defines the location of the image to be used as the overlay or placemark symbol. Its location can either be on a local file system or on a remote web server. A default icon will be used if uri is null or empty.

      Parameters:
      uri - a URI path to an image file
      Since:
      100.6.0
  • Method Details

    • getRefreshInterval

      public long getRefreshInterval()
      Gets the icon's refresh interval.
      Returns:
      the refresh interval in milliseconds
      Since:
      100.6.0
    • setRefreshInterval

      public void setRefreshInterval(long refreshInterval)
      Sets the icon's refresh interval.

      If the refresh interval is greater than zero, the image is refreshed every n milliseconds; if it is set to zero, the image is loaded only once; if it is not set and the refresh mode is {KmlRefreshMode.ON_INTERVAL} initially, the refresh interval will be set to 4000 milliseconds by default.

      Parameters:
      refreshInterval - the refresh interval in milliseconds
      Throws:
      IllegalArgumentException - if refreshInterval is negative
      Since:
      100.6.0
    • getRefreshMode

      public KmlRefreshMode getRefreshMode()
      Gets the icon's refresh mode.
      Returns:
      a KmlRefreshMode
      Since:
      100.6.0
    • setRefreshMode

      public void setRefreshMode(KmlRefreshMode kmlRefreshMode)
      Sets the icon's refresh mode.
      Parameters:
      kmlRefreshMode - a KmlRefreshMode
      Throws:
      IllegalArgumentException - if kmlRefreshMode is null
      Since:
      100.6.0
    • getURI

      public String getURI()
      Gets the icon's image file URI.
      Returns:
      the icon's image file URI
      Since:
      100.6.0
    • getViewRefreshMode

      public KmlViewRefreshMode getViewRefreshMode()
      Gets the icon's view refresh mode.
      Returns:
      a KmlViewRefreshMode
      Since:
      100.6.0
    • setViewRefreshMode

      public void setViewRefreshMode(KmlViewRefreshMode viewRefreshMode)
      Sets the icon's view refresh mode.
      Parameters:
      viewRefreshMode - a KmlViewRefreshMode
      Throws:
      IllegalArgumentException - if viewRefreshMode is null
      Since:
      100.6.0
    • getViewRefreshTime

      public long getViewRefreshTime()
      Gets the icon's view refresh time.

      It is the number of milliseconds to wait before refreshing the icon after camera movement stops.

      Returns:
      the icon's view refresh time in milliseconds
      Since:
      100.6.0
    • setViewRefreshTime

      public void setViewRefreshTime(long viewRefreshTime)
      Sets the icon's view refresh time.

      It is the number of milliseconds to wait before refreshing the icon after camera movement stops. If viewRefreshTime is not set when the mode is set to {KmlViewRefreshMode.ON_STOP}, it will automatically be set to 4000 milliseconds.

      Parameters:
      viewRefreshTime - the icon's view refresh time in milliseconds
      Throws:
      IllegalArgumentException - if viewRefreshTime is negative
      Since:
      100.6.0