|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object loci.formats.codec.BaseCodec
public abstract class BaseCodec
BaseCodec contains default implementation and testing for classes implementing the Codec interface, and acts as a base class for any of the compression classes. Base 1D compression and decompression methods are not implemented here, and are left as abstract. 2D methods do simple concatenation and call to the 1D methods
Constructor Summary | |
---|---|
BaseCodec()
|
Method Summary | |
---|---|
byte[] |
compress(byte[][] data,
int x,
int y,
int[] dims,
Object options)
2D data block encoding default implementation. |
byte[] |
decompress(byte[] data)
Decompresses a block of data. |
byte[] |
decompress(byte[][] data)
Decompresses a block of data. |
byte[] |
decompress(byte[][] data,
Object options)
2D data block decoding default implementation. |
void |
test()
Main testing method default implementation. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface loci.formats.codec.Codec |
---|
compress, decompress |
Constructor Detail |
---|
public BaseCodec()
Method Detail |
---|
public void test() throws loci.formats.FormatException
loci.formats.FormatException
- Can only occur if there is a bug in the
compress method.public byte[] compress(byte[][] data, int x, int y, int[] dims, Object options) throws loci.formats.FormatException
compress
in interface Codec
data
- The data to be compressed.x
- Length of the x dimension of the image data, if appropriate.y
- Length of the y dimension of the image data, if appropriate.dims
- The dimensions of the image data, if appropriate.options
- Options to be used during compression, if appropriate.
loci.formats.FormatException
- If input is not a compressed data block of the
appropriate type.public byte[] decompress(byte[] data) throws loci.formats.FormatException
Codec
decompress
in interface Codec
data
- the data to be decompressed.
loci.formats.FormatException
- If data is not valid compressed data for this
decompressor.public byte[] decompress(byte[][] data) throws loci.formats.FormatException
Codec
decompress
in interface Codec
data
- The data to be decompressed.
loci.formats.FormatException
- If data is not valid compressed data for this
decompressor.public byte[] decompress(byte[][] data, Object options) throws loci.formats.FormatException
decompress
in interface Codec
data
- The data to be decompressed.options
- Options to be used during decompression.
loci.formats.FormatException
- If input is not a compressed data block of the
appropriate type.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |