org.geotoolkit.image.io.plugin
Class AsciiGridWriter.Spi

Object
  extended by IIOServiceProvider
      extended by ImageReaderWriterSpi
          extended by ImageWriterSpi
              extended by SpatialImageWriter.Spi
                  extended by StreamImageWriter.Spi
                      extended by TextImageWriter.Spi
                          extended by AsciiGridWriter.Spi
All Implemented Interfaces:
RegisterableService
Enclosing class:
AsciiGridWriter

public static class AsciiGridWriter.Spi
extends TextImageWriter.Spi

Service provider interface (SPI) for AsciiGridWriters. This SPI provides the necessary implementation for creating default AsciiGridWriters using US locale and ASCII character set. The locale and charset fields are ignored by the default implementation.

The default constructor initializes the fields to the values listed below. Users wanting different values should create a subclass of Spi and set the desired values in their constructor.

FieldValue
 ImageReaderWriterSpi.names   "ascii-grid" 
 ImageReaderWriterSpi.MIMETypes   "text/plain", "text/x-ascii-grid" 
 ImageReaderWriterSpi.pluginClassName   "org.geotoolkit.image.io.plugin.AsciiGridWriter" 
 IIOServiceProvider.vendorName   "Geotoolkit.org" 
 IIOServiceProvider.version   Value of Version.GEOTOOLKIT 
 ImageWriter.locale   Locale.US 
 TextImageWriter.Spi.charset   "US-ASCII" 
 TextImageWriter.Spi.lineSeparator   "\n" 
See super-class javadoc for remaining fields

Since:
3.08 (derived from 3.07)
Version:
3.08
Author:
Martin Desruisseaux (Geomatys)
See Also:
AsciiGridReader.Spi
Module:
coverage/geotk-coverageio (download)    View source code for this class

Field Summary
 
Fields inherited from class TextImageWriter.Spi
charset, lineSeparator, locale
 
Fields inherited from class ImageWriterSpi
outputTypes, readerSpiNames, STANDARD_OUTPUT_TYPE
 
Fields inherited from class ImageReaderWriterSpi
extraImageMetadataFormatClassNames, extraImageMetadataFormatNames, extraStreamMetadataFormatClassNames, extraStreamMetadataFormatNames, MIMETypes, names, nativeImageMetadataFormatClassName, nativeImageMetadataFormatName, nativeStreamMetadataFormatClassName, nativeStreamMetadataFormatName, pluginClassName, suffixes, supportsStandardImageMetadataFormat, supportsStandardStreamMetadataFormat
 
Fields inherited from class IIOServiceProvider
vendorName, version
 
Constructor Summary
AsciiGridWriter.Spi()
          Constructs a default AsciiGridWriter.Spi.
 
Method Summary
 ImageWriter createWriterInstance(Object extension)
          Returns an instance of the ImageWriter implementation associated with this service provider.
 String getDescription(Locale locale)
          Returns a brief, human-readable description of this service provider and its associated implementation.
 
Methods inherited from class StreamImageWriter.Spi
canEncodeImage
 
Methods inherited from class SpatialImageWriter.Spi
addExtraMetadataFormat, getImageMetadataFormat, getStreamMetadataFormat
 
Methods inherited from class ImageWriterSpi
canEncodeImage, createWriterInstance, getImageReaderSpiNames, getOutputTypes, isFormatLossless, isOwnWriter
 
Methods inherited from class ImageReaderWriterSpi
getExtraImageMetadataFormatNames, getExtraStreamMetadataFormatNames, getFileSuffixes, getFormatNames, getMIMETypes, getNativeImageMetadataFormatName, getNativeStreamMetadataFormatName, getPluginClassName, isStandardImageMetadataFormatSupported, isStandardStreamMetadataFormatSupported
 
Methods inherited from class IIOServiceProvider
getVendorName, getVersion, onDeregistration, onRegistration
 
Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AsciiGridWriter.Spi

public AsciiGridWriter.Spi()
Constructs a default AsciiGridWriter.Spi. The fields are initialized as documented in the class javadoc. Subclasses can modify those values if desired.

For efficiency reasons, the above fields are initialized to shared arrays. Subclasses can assign new arrays, but should not modify the default array content.

Method Detail

getDescription

public String getDescription(Locale locale)
Returns a brief, human-readable description of this service provider and its associated implementation. The resulting string should be localized for the supplied locale, if possible.

Specified by:
getDescription in class IIOServiceProvider
Parameters:
locale - A Locale for which the return value should be localized.
Returns:
A String containing a description of this service provider.

createWriterInstance

public ImageWriter createWriterInstance(Object extension)
                                 throws IOException
Returns an instance of the ImageWriter implementation associated with this service provider.

Specified by:
createWriterInstance in class ImageWriterSpi
Parameters:
extension - An optional extension object, which may be null.
Returns:
An image writer instance.
Throws:
IOException - if the attempt to instantiate the writer fails.


Copyright © 2009-2013 Geotoolkit.org. All Rights Reserved.