|
JavaTM 2 Platform Standard Ed. 5.0 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object javax.imageio.spi.IIOServiceProvider javax.imageio.spi.ImageReaderWriterSpi javax.imageio.spi.ImageReaderSpi
public abstract class ImageReaderSpi
The service provider interface (SPI) for ImageReader
s.
For more information on service provider classes, see the class comment
for the IIORegistry
class.
Each ImageReaderSpi
provides several types of information
about the ImageReader
class with which it is associated.
The name of the vendor who defined the SPI class and a
brief description of the class are available via the
getVendorName
, getDescription
,
and getVersion
methods.
These methods may be internationalized to provide locale-specific
output. These methods are intended mainly to provide short,
human-readable information that might be used to organize a pop-up
menu or other list.
Lists of format names, file suffixes, and MIME types associated
with the service may be obtained by means of the
getFormatNames
, getFileSuffixes
, and
getMIMETypes
methods. These methods may be used to
identify candidate ImageReader
s for decoding a
particular file or stream based on manual format selection, file
naming, or MIME associations (for example, when accessing a file
over HTTP or as an email attachment).
A more reliable way to determine which ImageReader
s
are likely to be able to parse a particular data stream is provided
by the canDecodeInput
method. This methods allows the
service provider to inspect the actual stream contents.
Finally, an instance of the ImageReader
class
associated with this service provider may be obtained by calling
the createReaderInstance
method. Any heavyweight
initialization, such as the loading of native libraries or creation
of large tables, should be deferred at least until the first
invocation of this method.
IIORegistry
,
ImageReader
Field Summary | |
---|---|
protected Class[] |
inputTypes
An array of Class objects to be returned from
getInputTypes , initially null . |
static Class[] |
STANDARD_INPUT_TYPE
A single-element array, initially containing ImageInputStream.class , to be returned from
getInputTypes . |
protected String[] |
writerSpiNames
An array of strings to be returned from getImageWriterSpiNames , initially
null . |
Fields inherited from class javax.imageio.spi.IIOServiceProvider |
---|
vendorName, version |
Constructor Summary | |
---|---|
protected |
ImageReaderSpi()
Constructs a blank ImageReaderSpi . |
|
|