org.gerhardb.lib.image
Class IOImage

java.lang.Object
  extended byorg.gerhardb.lib.image.IOImage

public class IOImage
extends java.lang.Object

This is used to read images and write them back out to a file. This wraps the stream thereby keeping the Metadata.


Constructor Summary
IOImage(java.io.File file)
           
 
Method Summary
 void closeInput()
           
 java.awt.image.BufferedImage getImage()
          Gets a buffered image.
 javax.imageio.metadata.IIOMetadata getMetaData()
          THIS FUNCTION IS NOT USED AS OF MARCH 2.
static IOImage makeImage(java.io.File aFile)
           
 void save(java.awt.image.BufferedImage image, float quality)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

IOImage

public IOImage(java.io.File file)
        throws java.io.IOException
Method Detail

makeImage

public static IOImage makeImage(java.io.File aFile)
Returns:
Returns the image if good, else returns null.

getImage

public java.awt.image.BufferedImage getImage()
                                      throws java.io.IOException
Gets a buffered image. Note that the file lock will not go away until the BufferedImage goes away.

Returns:
null if no image was found.
Throws:
java.io.IOException

closeInput

public void closeInput()

getMetaData

public javax.imageio.metadata.IIOMetadata getMetaData()
                                               throws java.io.IOException
THIS FUNCTION IS NOT USED AS OF MARCH 2. INSTEAD WE USE THE NOAKES LIBRARIES.

Returns:
Throws:
java.io.IOException

save

public void save(java.awt.image.BufferedImage image,
                 float quality)
          throws java.io.IOException
Throws:
java.io.IOException


Copyright © 2002 Gerhard Beck. All rights reserved. Subject to GPL.