FileDocCategorySizeDatePackage
ImageOutputStreamSpi.javaAPI DocAndroid 1.5 API4418Wed May 06 22:41:54 BST 2009javax.imageio.spi

ImageOutputStreamSpi

public abstract class ImageOutputStreamSpi extends IIOServiceProvider implements RegisterableService
The ImageOutputStreamSpi abstract class is a service provider interface (SPI) for ImageOutputStreams.
since
Android 1.0

Fields Summary
protected Class
outputClass
The output class.
Constructors Summary
protected ImageOutputStreamSpi()
Instantiates a new ImageOutputStreamSpi.

        throw new UnsupportedOperationException("Not supported yet");
    
public ImageOutputStreamSpi(String vendorName, String version, Class outputClass)
Instantiates a new ImageOutputStreamSpi.

param
vendorName the vendor name.
param
version the version.
param
outputClass the output class.

        super(vendorName, version);
        this.outputClass = outputClass;
    
Methods Summary
public booleancanUseCacheFile()
Returns true if the ImageOutputStream can use a cache file. If this method returns false, the value of the useCache parameter of createOutputStreamInstance will be ignored. The default implementation returns false.

return
true, if the ImageOutputStream can use a cache file, false otherwise.

        return false; // def
    
public javax.imageio.stream.ImageOutputStreamcreateOutputStreamInstance(java.lang.Object output)
Creates the ImageOutputStream associated with this service provider. The output object should be an instance of the class returned by getOutputClass method. This method uses the default system directory for the cache file, if it is needed.

param
output the output Object.
return
the ImageOutputStream.
throws
IOException if an I/O exception has occurred.

        return createOutputStreamInstance(output, true, null);
    
public abstract javax.imageio.stream.ImageOutputStreamcreateOutputStreamInstance(java.lang.Object output, boolean useCache, java.io.File cacheDir)
Creates the ImageOutputStream associated with this service provider. The output object should be an instance of the class returned by getInputClass method. This method uses the specified directory for the cache file, if the useCache parameter is true.

param
output the output Object.
param
useCache the flag indicating if cache file is needed or not.
param
cacheDir the cache directory.
return
the ImageOutputStream.
throws
IOException if an I/O exception has occurred.

public java.lang.ClassgetOutputClass()
Gets an output Class object that represents the class or interface that must be implemented by an output source.

return
the output class.

        return outputClass;
    
public booleanneedsCacheFile()
Returns true if the ImageOutputStream implementation requires the use of a cache file. The default implementation returns false.

return
true, if the ImageOutputStream implementation requires the use of a cache file, false otherwise.

        return false; // def