Class TLcdEarthTileFormat

java.lang.Object
com.luciad.earth.tileset.TLcdEarthTileFormat

public class TLcdEarthTileFormat extends Object
Describes a tile's data format, using a Class and/or a Name. The Class is used to cast the tile's data to, e.g. byte[]. The name is used to further specify the data content, e.g. "JPEG". At least one of the parameters must not be null.

The class should not be null if the format describes data that is available in a java object. It can however be null if the format describes some data that exists on an external resource. Some examples:

Described dataClassName
an ALcdEarthTile with a BufferedImage as data BufferedImage.class null
an ALcdEarthTile with a byte[], that contains a jpeg encoded image, as data byte[].class jpeg
an ILcdEarthTileSetCoverage with jpeg encoded data on disk null jpeg

The format name is case insensitive, e.g. "JPEG" is the same as "Jpeg".

Since:
8.2
See Also:
  • Constructor Details

    • TLcdEarthTileFormat

      public TLcdEarthTileFormat(String aFormatName, Class aFormatClass)
      Creates a new tile data format using the given parameters.
      Parameters:
      aFormatName - the name of the format
      aFormatClass - the Class of the format
    • TLcdEarthTileFormat

      public TLcdEarthTileFormat(String aFormatName)
      Creates a new tile data format using only a name.
      Parameters:
      aFormatName - the name of the format, not null
    • TLcdEarthTileFormat

      public TLcdEarthTileFormat(Class aFormatClass)
      Creates a new tile data format using only a Class.
      Parameters:
      aFormatClass - the Class of the format
  • Method Details

    • getFormatClass

      public Class getFormatClass()
      Returns the Class to which data of the format may be casted.
      Returns:
      the data's Class
    • getFormatName

      public String getFormatName()
      Returns the name of the format.
      Returns:
      a descriptive name for the format
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • equals

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

      public int hashCode()
      Overrides:
      hashCode in class Object