com.esri.arcgis.datasourcesraster
Class SimplePixelReader

java.lang.Object
  extended by com.esri.arcgis.datasourcesraster.SimplePixelReader
All Implemented Interfaces:
IPixelReader, ISimplePixelReader, com.esri.arcgis.interop.RemoteObjRef, Serializable

public class SimplePixelReader
extends Object
implements com.esri.arcgis.interop.RemoteObjRef, IPixelReader, ISimplePixelReader

A simple pixel resampler class.

Description

The SimplePixelReader object is used to provide input pixels for RasterXformer. The SimplePixelReader can get pixels from a Raster or a call back function implemented by the developer using IRawPixelReader interface.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

See Also:
Serialized Form

Constructor Summary
SimplePixelReader()
          Constructs a SimplePixelReader using ArcGIS Engine.
SimplePixelReader(Object obj)
          Deprecated. As of ArcGIS 9.2, replaced by normal Java casts.
SimplePixelReader theSimplePixelReader = (SimplePixelReader) obj;
 
Method Summary
 boolean equals(Object o)
          Compare this object with another
 int getBandCount()
          The number of source bands.
 IPnt getCellSize()
          The source original cell size.
static String getClsid()
          getClsid.
 IEnvelope getExtent()
          The source full extent.
 int getFirstPyramidLevel()
          The first available source pyramid level.
 int getMaximumPyramidLevel()
          The maximum available source pyramid level.
 int getPixelType()
          The source pixel type.
 int getPyramidLevel()
          The current source pyramid level.
 void getResolution(int level, double[] pXResolution, double[] pYResolution)
          Gets X and Y resolution (cellsize) at a given level.
 int hashCode()
          the hashcode for this object
 void read(IPnt tlc, IPixelBlock pPixelBlock)
          Reads a pixel block.
 void setBandCount(int rhs1)
          The number of source bands.
 void setCellSize(IPnt rhs1)
          The source original cell size.
 void setExtent(IEnvelope rhs1)
          The source full extent.
 void setFirstPyramidLevel(int rhs1)
          The first available source pyramid level.
 void setMaximumPyramidLevel(int rhs1)
          The maximum available source pyramid level.
 void setPixelType(int rhs1)
          The source pixel type.
 void setPyramidLevel(int pLevel)
          The current source pyramid level.
 void setRasterByRef(IRaster rhs1)
          The source raster providing pixels.
 void setRawPixelReaderByRef(IRawPixelReader rhs1)
          The raw pixel reader callback.
 int snap(double dx, double dy)
          Snaps a given cellsize to a proper pyramid level.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.esri.arcgis.interop.RemoteObjRef
getJintegraDispatch, release
 

Constructor Detail

SimplePixelReader

public SimplePixelReader()
                  throws IOException,
                         UnknownHostException
Constructs a SimplePixelReader using ArcGIS Engine.

Throws:
IOException - if there are interop problems
UnknownHostException - if there are interop problems

SimplePixelReader

public SimplePixelReader(Object obj)
                  throws IOException
Deprecated. As of ArcGIS 9.2, replaced by normal Java casts.
SimplePixelReader theSimplePixelReader = (SimplePixelReader) obj;

Construct a SimplePixelReader using a reference to such an object returned from ArcGIS Engine or Server. This is semantically equivalent to casting obj to SimplePixelReader.

Parameters:
obj - an object returned from ArcGIS Engine or Server
Throws:
IOException - if there are interop problems
Method Detail

getClsid

public static String getClsid()
getClsid.


equals

public boolean equals(Object o)
Compare this object with another

Overrides:
equals in class Object

hashCode

public int hashCode()
the hashcode for this object

Overrides:
hashCode in class Object

getPixelType

public int getPixelType()
                 throws IOException,
                        AutomationException
The source pixel type.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
getPixelType in interface IPixelReader
Returns:
A com.esri.arcgis.geodatabase.rstPixelType constant
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getBandCount

public int getBandCount()
                 throws IOException,
                        AutomationException
The number of source bands.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
getBandCount in interface IPixelReader
Returns:
The pBandCount
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getExtent

public IEnvelope getExtent()
                    throws IOException,
                           AutomationException
The source full extent.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
getExtent in interface IPixelReader
Returns:
A reference to a com.esri.arcgis.geometry.IEnvelope
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getCellSize

public IPnt getCellSize()
                 throws IOException,
                        AutomationException
The source original cell size.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
getCellSize in interface IPixelReader
Returns:
A reference to a com.esri.arcgis.geodatabase.IPnt
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getMaximumPyramidLevel

public int getMaximumPyramidLevel()
                           throws IOException,
                                  AutomationException
The maximum available source pyramid level.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
getMaximumPyramidLevel in interface IPixelReader
Returns:
The pMaxLevel
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getFirstPyramidLevel

public int getFirstPyramidLevel()
                         throws IOException,
                                AutomationException
The first available source pyramid level.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
getFirstPyramidLevel in interface IPixelReader
Returns:
The pFirstLevel
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getPyramidLevel

public int getPyramidLevel()
                    throws IOException,
                           AutomationException
The current source pyramid level.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
getPyramidLevel in interface IPixelReader
Returns:
The pLevel
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setPyramidLevel

public void setPyramidLevel(int pLevel)
                     throws IOException,
                            AutomationException
The current source pyramid level.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
setPyramidLevel in interface IPixelReader
Parameters:
pLevel - The pLevel (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

read

public void read(IPnt tlc,
                 IPixelBlock pPixelBlock)
          throws IOException,
                 AutomationException
Reads a pixel block.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
read in interface IPixelReader
Parameters:
tlc - A reference to a com.esri.arcgis.geodatabase.IPnt (in)
pPixelBlock - A reference to a com.esri.arcgis.geodatabase.IPixelBlock (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

snap

public int snap(double dx,
                double dy)
         throws IOException,
                AutomationException
Snaps a given cellsize to a proper pyramid level.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
snap in interface IPixelReader
Parameters:
dx - The dx (in)
dy - The dy (in)
Returns:
The pLevel
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getResolution

public void getResolution(int level,
                          double[] pXResolution,
                          double[] pYResolution)
                   throws IOException,
                          AutomationException
Gets X and Y resolution (cellsize) at a given level.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
getResolution in interface IPixelReader
Parameters:
level - The level (in)
pXResolution - The pXResolution (out: use single element array)
pYResolution - The pYResolution (out: use single element array)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setPixelType

public void setPixelType(int rhs1)
                  throws IOException,
                         AutomationException
The source pixel type.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
setPixelType in interface ISimplePixelReader
Parameters:
rhs1 - A com.esri.arcgis.geodatabase.rstPixelType constant (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setBandCount

public void setBandCount(int rhs1)
                  throws IOException,
                         AutomationException
The number of source bands.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
setBandCount in interface ISimplePixelReader
Parameters:
rhs1 - The rhs1 (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setExtent

public void setExtent(IEnvelope rhs1)
               throws IOException,
                      AutomationException
The source full extent.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
setExtent in interface ISimplePixelReader
Parameters:
rhs1 - A reference to a com.esri.arcgis.geometry.IEnvelope (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setCellSize

public void setCellSize(IPnt rhs1)
                 throws IOException,
                        AutomationException
The source original cell size.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
setCellSize in interface ISimplePixelReader
Parameters:
rhs1 - A reference to a com.esri.arcgis.geodatabase.IPnt (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setMaximumPyramidLevel

public void setMaximumPyramidLevel(int rhs1)
                            throws IOException,
                                   AutomationException
The maximum available source pyramid level.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
setMaximumPyramidLevel in interface ISimplePixelReader
Parameters:
rhs1 - The rhs1 (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setFirstPyramidLevel

public void setFirstPyramidLevel(int rhs1)
                          throws IOException,
                                 AutomationException
The first available source pyramid level.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
setFirstPyramidLevel in interface ISimplePixelReader
Parameters:
rhs1 - The rhs1 (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setRawPixelReaderByRef

public void setRawPixelReaderByRef(IRawPixelReader rhs1)
                            throws IOException,
                                   AutomationException
The raw pixel reader callback.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
setRawPixelReaderByRef in interface ISimplePixelReader
Parameters:
rhs1 - A reference to a com.esri.arcgis.datasourcesraster.IRawPixelReader (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setRasterByRef

public void setRasterByRef(IRaster rhs1)
                    throws IOException,
                           AutomationException
The source raster providing pixels.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Specified by:
setRasterByRef in interface ISimplePixelReader
Parameters:
rhs1 - A reference to a com.esri.arcgis.geodatabase.IRaster (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.