Class Driver

Object
Driver

public final class Driver extends Object
Information about a GDAL driver.
Since:
1.5
  • Method Details

    • getName

      public String getName() throws DataStoreException
      Returns the long name of the driver. For the GeoTIFF driver, this is "Geo­TIFF".
      Returns:
      the driver long name, or null.
      Throws:
      Data­Store­Exception - if an error occurred while invoking a GDAL function.
    • getIdentifier

      public String getIdentifier() throws DataStoreException
      Returns the short name of the driver. For the GeoTIFF driver, this is "GTiff". This is the name used by GDAL for identifying a driver on the command-line.
      Returns:
      the driver short name, or null.
      Throws:
      Data­Store­Exception - if an error occurred while invoking a GDAL function.
      See Also:
    • getMIMEType

      public String getMIMEType() throws DataStoreException
      Returns the MIME type handled by the driver.
      Returns:
      the MIME type handled by the driver, or null if unspecified.
      Throws:
      Data­Store­Exception - if an error occurred while invoking a GDAL function.
    • getFileSuffixes

      public String[] getFileSuffixes() throws DataStoreException
      Returns the file extensions handled by the driver.
      Returns:
      the file extensions handled by the driver, or an empty array if none.
      Throws:
      Data­Store­Exception - if an error occurred while invoking a GDAL function.
      See Also:
    • supportRasters

      public boolean supportRasters() throws DataStoreException
      Returns whether the driver has raster capability.
      Returns:
      whether the driver has raster capability.
      Throws:
      Data­Store­Exception - if an error occurred while invoking a GDAL function.
    • getMetadataItem

      public String getMetadataItem(String name, String domain) throws DataStoreException
      Fetches a single metadata item. The following table lists some metadata:
      Some metadata keys
      Key Description
      "DMD_MIMETYPE" MIME type handled by the driver.
      "DMD_EXTENSIONS" space separated list of file extensions handled by the driver.
      "DCAP_RASTER" Whether the driver has raster capability.
      Parameters:
      name - the key for the metadata item to fetch.
      domain - the domain to fetch for, or null for the default domain.
      Returns:
      the metadata item value, or null if none.
      Throws:
      Data­Store­Exception - if an error occurred while invoking a GDAL function.
    • toString

      public String toString()
      Returns a string representation of this driver for debugging purposes.
      Overrides:
      to­String in class Object
      Returns:
      a string representation of this driver.