Class TLcdEarthTile

java.lang.Object
com.luciad.earth.tileset.ALcdEarthTile
com.luciad.earth.tileset.TLcdEarthTile
All Implemented Interfaces:
ILcdBounded, ILcdCache

public class TLcdEarthTile extends ALcdEarthTile
Default implementation of ALcdEarthTile.
Since:
8.2
  • Constructor Details

    • TLcdEarthTile

      public TLcdEarthTile(ILcdBounds aBounds, Object aData, int aLevel, long aTileX, long aTileY, ILcdEarthTileSetCoverage aCoverage, ILcdGeoReference aGeoReference, TLcdEarthTileFormat aFormat)
      Creates a new TLcdEarthTile with the given parameters and the current date as its creation date.
      Parameters:
      aBounds - the bounds of the tile
      aData - the data contained in the tile
      aLevel - the level of the tile
      aTileX - the column index of the tile
      aTileY - the row index of the tile
      aCoverage - the coverage of the tile
      aGeoReference - the reference of the tile
      aFormat - the format of the tile's data
    • TLcdEarthTile

      public TLcdEarthTile(ILcdBounds aBounds, Object aData, int aLevel, long aTileX, long aTileY, ILcdEarthTileSetCoverage aCoverage, ILcdGeoReference aGeoReference, TLcdEarthTileFormat aFormat, Date aCreationDate)
      Creates a new TLcdEarthTile with the given parameters.
      Parameters:
      aBounds - the bounds of the tile
      aData - the data contained in the tile
      aLevel - the level of the tile
      aTileX - the column index of the tile
      aTileY - the row index of the tile
      aCoverage - the coverage of the tile
      aGeoReference - the reference of the tile
      aFormat - the format of the tile's data
      aCreationDate - the creation date of the tile's date
  • Method Details

    • getDataFormat

      public TLcdEarthTileFormat getDataFormat()
      Description copied from class: ALcdEarthTile
      Returns the tile data's format. This format describes the return type of ALcdEarthTile.getData().
      Specified by:
      getDataFormat in class ALcdEarthTile
      Returns:
      a TLcdEarthTileFormat.
    • getData

      public Object getData()
      Description copied from class: ALcdEarthTile
      Returns the tile's data. The type of this data can be retrieved using the ALcdEarthTile.getDataFormat() method.
      Specified by:
      getData in class ALcdEarthTile
      Returns:
      the tile's data
    • getBounds

      public ILcdBounds getBounds()
      Description copied from interface: ILcdBounded
      Returns the ILcdBounds by which the geometry of this ILcdBounded object is bounded.

      If the geometry does not allow retrieving valid bounds (for example a polyline with 0 points) the return value is unspecified. It is highly recommended to return an undefined bounds. You can create undefined bounds using the default constructors of TLcdLonLatBounds or TLcdXYBounds.

      Returns:
      the ILcdBounds by which the geometry of this ILcdBounded object is bounded.
    • getLevel

      public int getLevel()
      Description copied from class: ALcdEarthTile
      Returns the detail level to which this tile belongs.
      Specified by:
      getLevel in class ALcdEarthTile
      Returns:
      the detail level to which this tile belongs
    • getTileX

      public long getTileX()
      Description copied from class: ALcdEarthTile
      Returns the tile's column index.
      Specified by:
      getTileX in class ALcdEarthTile
      Returns:
      the tile's column index
    • getTileY

      public long getTileY()
      Description copied from class: ALcdEarthTile
      Returns the tile's row index.
      Specified by:
      getTileY in class ALcdEarthTile
      Returns:
      the tile's row index
    • getTileSetCoverage

      public ILcdEarthTileSetCoverage getTileSetCoverage()
      Description copied from class: ALcdEarthTile
      Returns the coverage to which this tile belongs.
      Specified by:
      getTileSetCoverage in class ALcdEarthTile
      Returns:
      the coverage to which this tile belongs
    • getGeoReference

      public ILcdGeoReference getGeoReference()
      Description copied from class: ALcdEarthTile
      Returns the georeference of the tile's data. This is not necessarily equal to the coverage's native georeference.
      Specified by:
      getGeoReference in class ALcdEarthTile
      Returns:
      the georeference of tile's data
    • isComplete

      public boolean isComplete()
      Description copied from class: ALcdEarthTile
      If false, this tile represents a partially loaded chunk of data. The tileset will invoke its callback one or more additional times for the same tile until the tile is completely produced, at which point this method will return true. This mechanism can be used to support progressive streaming of terrain data.
      Specified by:
      isComplete in class ALcdEarthTile
      Returns:
      true if the tile is complete
    • getCompleteness

      public float getCompleteness()
      Description copied from class: ALcdEarthTile
      Returns the tile's completeness, that is the progress level to reach the complete status. The returned value is in the range [0,1], where 1 = complete. Note: this method should return 1 when the isComplete method returns true and vice-versa. This mechanism can be used to support progressive streaming of terrain data.
      Specified by:
      getCompleteness in class ALcdEarthTile
      Returns:
      a float value in the range [0,1], representing the tile's completeness.
    • getCreationDate

      public Date getCreationDate()
      Description copied from class: ALcdEarthTile
      Returns the date the tile and its data were created. This can be used to check whether the tile is outdated.
      Specified by:
      getCreationDate in class ALcdEarthTile
      Returns:
      creation date of the tile
    • 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
    • insertIntoCache

      public void insertIntoCache(Object aKey, Object aObject)
      Description copied from interface: ILcdCache
      Inserts a cache Object corresponding to the given key Object.
      Parameters:
      aKey - the key Object that will be used to identify the Object. The key must therefore be a unique identifier, typically the caller itself: insertIntoCache(this, ...).
      aObject - the Object to be cached.
    • getCachedObject

      public Object getCachedObject(Object aKey)
      Description copied from interface: ILcdCache
      Looks up and returns the cached Object corresponding to the given key.
      Parameters:
      aKey - the key Object that was used for storing the cache Object.
      Returns:
      the cached Object, or null if there is no Object corresponding to the given key.
    • removeCachedObject

      public Object removeCachedObject(Object aKey)
      Description copied from interface: ILcdCache
      Looks up and removes the cached Object corresponding to the given key.
      Parameters:
      aKey - the key Object that was used for storing the cache Object.
      Returns:
      the cached Object, or null if there was no Object corresponding to the given key.
    • clearCache

      public void clearCache()
      Description copied from interface: ILcdCache
      Clears the cache.