## javax.media.jai.tilecodec
Class TileCodecDescriptorImpl

    java.lang.Object
      |
      +--javax.media.jai.tilecodec.TileCodecDescriptorImpl

All Implemented Interfaces:
  RegistryElementDescriptor, TileCodecDescriptor

Direct Known Subclasses:
  GZIPTileCodecDescriptor, JPEGTileCodecDescriptor, RawTileCodecDescriptor

public abstract class TileCodecDescriptorImpl
extends java.lang.Object
implements TileCodecDescriptor

An abstract class that implements the `TileCodecDescriptor` interface and is suitable for subclassing. This class provides default implementations for some of the methods from `TileCodecDescriptor`. Subclasses should override these methods if they do not wish to retain the default implementation. All `String`s are treated in a case-retentive and case-insensitive manner.

Since:
  1.1

Constructor Summary
`TileCodecDescriptorImpl(java.lang.String formatName, boolean includesSampleModelInfo, boolean includesLocationInfo)` Creates a `TileCodecDescriptorImpl` with the given format name and `boolean`s to specify whether layout information is included in the encoded stream.

Method Summary
`boolean` `arePropertiesSupported()` Whether this descriptor supports properties.
`java.lang.String` `getName()` Returns the name of the format.
`PropertyGenerator[]` `getPropertyGenerators(java.lang.String modeName)` Returns an array of `PropertyGenerator`s implementing the property inheritance for this operation.
`java.lang.String[]` `getSupportedModes()` Returns the registry modes supported by this descriptor.
`boolean` `includesLocationInfo()` Returns true if the format encodes in the data stream the location of the `Raster` with respect to its enclosing image.
`boolean` `includesSampleModelInfo()` Returns true if the format encodes layout information generally specified via the `SampleModel` in the encoded data stream.
`boolean` `isModeSupported(java.lang.String registryModeName)` This method is implemented to return true if the specified registryModeName is either "tileDecoder" or "tileEncoder".

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Methods inherited from interface javax.media.jai.tilecodec.TileCodecDescriptor
`getCompatibleParameters, getDefaultParameters, getDefaultParameters`

Methods inherited from interface javax.media.jai.RegistryElementDescriptor
`getParameterListDescriptor`

Constructor Detail

### TileCodecDescriptorImpl

    public TileCodecDescriptorImpl(java.lang.String formatName,
                                   boolean includesSampleModelInfo,
                                   boolean includesLocationInfo)

  Creates a `TileCodecDescriptorImpl` with the given format name and `boolean`s to specify whether layout information is included in the encoded stream.
  Parameters:
    `formatName` - The name of the format. This is also the name under which this descriptor will be registered under in the `OperationRegistry`.
    `includesSampleModelInfo` - Whether the format encodes the tile's `SampleModel` or equivalent information into the encoded stream.
    `includesLocationInfo` - Whether the format encodes the tile's upper left corner position or equivalent information into the encoded stream.
  Throws:
    `java.lang.IllegalArgumentException` - if formatName is null.

Method Detail

### getName

    public java.lang.String getName()

  Returns the name of the format.
  Specified by:
    `getName` in interface `RegistryElementDescriptor`

### getSupportedModes

    public java.lang.String[] getSupportedModes()

  Returns the registry modes supported by this descriptor. The default implementation of this method in this class returns a `String` array containing the "tileDecoder" and "tileEncoder" strings. If the subclass does not support any of these modes, it should override this method to return the names of those modes that it supports.
  Specified by:
    `getSupportedModes` in interface `RegistryElementDescriptor`
  See Also:
    `RegistryMode`

### isModeSupported

    public boolean isModeSupported(java.lang.String registryModeName)

  This method is implemented to return true if the specified registryModeName is either "tileDecoder" or "tileEncoder". If the subclass doesn't support any one of these modes, it should override this method to return true only for the supported mode(s).
  Specified by:
    `isModeSupported` in interface `RegistryElementDescriptor`
  Parameters:
    `registryModeName` - The name of the registry mode to check support for.
  Throws:
    `java.lang.IllegalArgumentException` - if registryModeName is null.

### arePropertiesSupported

    public boolean arePropertiesSupported()

  Whether this descriptor supports properties.
  Specified by:
    `arePropertiesSupported` in interface `RegistryElementDescriptor`
  Returns:
    true, if the implementation of this descriptor supports properties. false otherwise. Since tile codecs do not support properties, so this default implementation returns false.
  See Also:
    `PropertyGenerator`

### getPropertyGenerators

    public PropertyGenerator[] getPropertyGenerators(java.lang.String modeName)

  Returns an array of `PropertyGenerator`s implementing the property inheritance for this operation. Since neither `TileEncoder` or `TileDecoder` supports properties, the default implementation throws an `UnsupportedOperationException`. Subclasses should override this method if they wish to produce inherited properties.
  Specified by:
    `getPropertyGenerators` in interface `RegistryElementDescriptor`
  Throws:
    `java.lang.IllegalArgumentException` - if `modeName` is null.
    `UnsupportedOperationException` - if `arePropertiesSupported()` returns `false`

### includesSampleModelInfo

    public boolean includesSampleModelInfo()

  Returns true if the format encodes layout information generally specified via the `SampleModel` in the encoded data stream.
  Specified by:
    `includesSampleModelInfo` in interface `TileCodecDescriptor`

### includesLocationInfo

    public boolean includesLocationInfo()

  Returns true if the format encodes in the data stream the location of the `Raster` with respect to its enclosing image.
  Specified by:
    `includesLocationInfo` in interface `TileCodecDescriptor`