|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.deegree.coverage.raster.data.info.RasterDataInfo
public class RasterDataInfo
The RasterDataInfo class encapsulates
| Field Summary | |
|---|---|
BandType[] |
bandInfo
The definitions of the bands |
int |
bands
The number of bands of the raster data |
int |
dataSize
The byte size of a single band unit |
DataType |
dataType
The datatype of the data |
InterleaveType |
interleaveType
Interleave information |
byte[] |
noDataPixel
The values of the bands, which are used for no data. |
| Constructor Summary | |
|---|---|
RasterDataInfo(BandType[] bandInfo,
DataType dataType,
InterleaveType interleaveType)
create a new RasterDataInfo and initialize the no data pixel with null. |
|
RasterDataInfo(byte[] noDataPixel,
BandType[] bandInfo,
DataType dataType,
InterleaveType interleaveType)
|
|
| Method Summary | |
|---|---|
int |
bands()
|
boolean |
equals(java.lang.Object other)
|
BandType[] |
getBandInfo()
|
byte |
getByteNoDataForBand(int band)
Returns the no data value for the given band, if the band is outside the number of bands or the given type is not of DataType.BYTE 0 will be returned. |
int |
getDataSize()
|
DataType |
getDataType()
|
double |
getDoubleNoDataForBand(int band)
Returns the no data value for the given band, if the band is outside the number of bands or the given type is not of DataType.DOUBLE 0 will be returned. |
float |
getFloatNoDataForBand(int band)
Returns the no data value for the given band, if the band is outside the number of bands or the given type is not of DataType.FLOAT 0 will be returned. |
InterleaveType |
getInterleaveType()
|
int |
getIntNoDataForBand(int band)
Returns the no data value for the given band, if the band is outside the number of bands or the given type is not of DataType.INT 0 will be returned. |
byte[] |
getNoDataPixel(BandType[] bands)
Returns the no data values for this raster's bands |
byte[] |
getNoDataPixel(byte[] result)
Returns the no data values for this raster's bands |
byte[] |
getNoDataSample(int band,
byte[] result)
Returns the no data values for the given band. |
short |
getShortNoDataForBand(int band)
Returns the no data value for the given band, if the band is outside the number of bands or the given type is not of DataType.SHORT or DataType.USHORT 0 will be returned. |
int |
hashCode()
Implementation as proposed by Joshua Block in Effective Java (Addison-Wesley 2001), which supplies an even distribution and is relatively fast. |
void |
setNoDataPixel(byte[] values)
Sets the no data values for this raster's bands |
java.lang.String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public final byte[] noDataPixel
public final BandType[] bandInfo
public final DataType dataType
public final InterleaveType interleaveType
public final int bands
public final int dataSize
| Constructor Detail |
|---|
public RasterDataInfo(byte[] noDataPixel,
BandType[] bandInfo,
DataType dataType,
InterleaveType interleaveType)
noDataPixel - to be used if no data was found in a given subset.bandInfo - of the raster datadataType - of the raster datainterleaveType - of the raster data.
public RasterDataInfo(BandType[] bandInfo,
DataType dataType,
InterleaveType interleaveType)
RasterDataInfo and initialize the no data pixel with null.
bandInfo - of the raster datadataType - of the raster datainterleaveType - of the raster data.| Method Detail |
|---|
public final BandType[] getBandInfo()
public final int bands()
getBandInfo().lengthpublic final DataType getDataType()
public final InterleaveType getInterleaveType()
public byte[] getNoDataPixel(byte[] result)
result - an array to put the values into or null
result array or a new array, if the result array is null or to
smallpublic byte[] getNoDataPixel(BandType[] bands)
bands - to copy the null data pixel values for.
result array or a new array, if the result array is null
public byte[] getNoDataSample(int band,
byte[] result)
null or is to small for the datasize, a new allocated byte array will be returned. Otherwise the
no data value for the requested band is copied at position 0 of the result array.
band - to get the value for.result - to put the value in.
result array or a new array, if the result array is nullpublic byte getByteNoDataForBand(int band)
DataType.BYTE 0 will be returned.
band - to get the no data value for.
public short getShortNoDataForBand(int band)
DataType.SHORT or DataType.USHORT 0 will be returned.
band - to get the no data value for.
public int getIntNoDataForBand(int band)
DataType.INT 0 will be returned.
band - to get the no data value for.
public float getFloatNoDataForBand(int band)
DataType.FLOAT 0 will be returned.
band - to get the no data value for.
public double getDoubleNoDataForBand(int band)
DataType.DOUBLE 0 will be returned.
band - to get the no data value for.
public void setNoDataPixel(byte[] values)
values - an array with the null valuespublic int getDataSize()
public boolean equals(java.lang.Object other)
equals in class java.lang.Objectpublic int hashCode()
Combining the hash code(s) computed above: result = 37 * result + code;
hashCode in class java.lang.ObjectObject.hashCode()public java.lang.String toString()
toString in class java.lang.Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||