deegree-core-3.0-pre-nightly (2010/03/05 00:01) - official

org.deegree.coverage.raster.io.imageio
Class IIORasterDataReader

java.lang.Object
  extended by org.deegree.coverage.raster.io.imageio.IIORasterDataReader
All Implemented Interfaces:
RasterDataReader

public class IIORasterDataReader
extends Object
implements RasterDataReader

Version:
$Revision: 22041 $, $Date: 2010-01-20 15:35:26 +0100 (Mi, 20 Jan 2010) $
Author:
Oliver Tonnhofer, last edited by: $Author: rbezema $

Constructor Summary
IIORasterDataReader(File file, RasterIOOptions options)
          Create a IIORasterDataReader for given file
IIORasterDataReader(InputStream stream, RasterIOOptions options)
          Create a IIORasterDataReader for given stream
 
Method Summary
 void close()
          Removes the internal references to the loaded raster to allow garbage collection of the raster.
 void dispose()
           
protected  File file()
          needed by the raster reader,
 int getHeight()
          Returns the height of the raster associated with the reader
protected  IIOMetadata getMetaData()
           
 RasterDataInfo getRasterDataInfo()
           
 boolean getReadTiles()
           
 int getWidth()
          Returns the height of the raster associated with the reader
 ByteBufferRasterData read()
          Reads data and returns a new RasterData object
 BufferResult read(RasterRect rect, ByteBuffer resultBuffer)
           
(package private)  boolean shouldCreateCacheFile()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

IIORasterDataReader

public IIORasterDataReader(File file,
                           RasterIOOptions options)
Create a IIORasterDataReader for given file

Parameters:
file - file to read
options - with values.

IIORasterDataReader

public IIORasterDataReader(InputStream stream,
                           RasterIOOptions options)
Create a IIORasterDataReader for given stream

Parameters:
stream - stream to read
options - with values
Method Detail

read

public ByteBufferRasterData read()
Reads data and returns a new RasterData object

Specified by:
read in interface RasterDataReader
Returns:
new RasterData

getWidth

public int getWidth()
Returns the height of the raster associated with the reader

Specified by:
getWidth in interface RasterDataReader
Returns:
raster height

getHeight

public int getHeight()
Returns the height of the raster associated with the reader

Specified by:
getHeight in interface RasterDataReader
Returns:
raster height

getMetaData

protected IIOMetadata getMetaData()
Returns:
the raw metadata of the raster

getRasterDataInfo

public RasterDataInfo getRasterDataInfo()
Returns:
the raster data info object describing the data to be read.

close

public void close()
Removes the internal references to the loaded raster to allow garbage collection of the raster.

Specified by:
close in interface RasterDataReader

file

protected File file()
needed by the raster reader,

Returns:
will return the file if any.

shouldCreateCacheFile

boolean shouldCreateCacheFile()
Returns:
true if the imageio thinks the file can be accessed easily

read

public BufferResult read(RasterRect rect,
                         ByteBuffer resultBuffer)
Parameters:
rect -
resultBuffer -
Returns:
the buffer result containing the result buffer (instantiated if the given one was null) and the rect it is valid for.

getReadTiles

public boolean getReadTiles()
Returns:
true if random access is easy for the image io reader.

dispose

public void dispose()

deegree-core-3.0-pre-nightly (2010/03/05 00:01) - official

an open source project founded by lat/lon, Bonn, Germany.
For more information visit: http://www.deegree.org

]]>