loci.formats.codec
Class LuraWaveCodec

java.lang.Object
  extended by loci.formats.codec.BaseCodec
      extended by loci.formats.codec.LuraWaveCodec
All Implemented Interfaces:
Codec

public class LuraWaveCodec
extends BaseCodec
implements Codec

This class provides LuraWave decompression, using LuraWave's Java decoding library. Compression is not supported. Decompression requires a LuraWave license code, specified in the lurawave.license system property (e.g., -Dlurawave.license=XXXX on the command line).

Source code:
Trac, SVN

Author:
Curtis Rueden ctrueden at wisc.edu

Field Summary
static String INVALID_LICENSE_MSG
          Message to display if an invalid LuraWave license code is given.
static String LICENSE_PROPERTY
          System property to check for the LuraWave license code.
protected static String licenseCode
          License code for LuraWave decoding library.
static String NO_LICENSE_MSG
          Message to display if no LuraWave license code is given.
static String NO_LURAWAVE_MSG
          Message displayed if the LuraWave LWF decoder library is not found.
protected static boolean noLuraWave
          True iff the LuraWave decoding library is not available.
protected static loci.formats.ReflectedUniverse r
          Reflected universe for LuraWave decoding library calls.
 
Constructor Summary
LuraWaveCodec()
           
 
Method Summary
 byte[] compress(byte[] data, int x, int y, int[] dims, Object options)
          Compresses a block of data.
 byte[] decompress(byte[] input, Object options)
          Decompresses a block of data.
 
Methods inherited from class loci.formats.codec.BaseCodec
compress, decompress, decompress, decompress, test
 
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, decompress, decompress
 

Field Detail

LICENSE_PROPERTY

public static final String LICENSE_PROPERTY
System property to check for the LuraWave license code.

See Also:
Constant Field Values

NO_LURAWAVE_MSG

public static final String NO_LURAWAVE_MSG
Message displayed if the LuraWave LWF decoder library is not found.

See Also:
Constant Field Values

NO_LICENSE_MSG

public static final String NO_LICENSE_MSG
Message to display if no LuraWave license code is given.

See Also:
Constant Field Values

INVALID_LICENSE_MSG

public static final String INVALID_LICENSE_MSG
Message to display if an invalid LuraWave license code is given.

See Also:
Constant Field Values

noLuraWave

protected static boolean noLuraWave
True iff the LuraWave decoding library is not available.


licenseCode

protected static String licenseCode
License code for LuraWave decoding library.


r

protected static loci.formats.ReflectedUniverse r
Reflected universe for LuraWave decoding library calls.

Constructor Detail

LuraWaveCodec

public LuraWaveCodec()
Method Detail

compress

public byte[] compress(byte[] data,
                       int x,
                       int y,
                       int[] dims,
                       Object options)
                throws loci.formats.FormatException
Description copied from interface: Codec
Compresses a block of data.

Specified by:
compress in interface Codec
Parameters:
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.
Returns:
The compressed data.
Throws:
loci.formats.FormatException - If input is not a compressed data block of the appropriate type.

decompress

public byte[] decompress(byte[] input,
                         Object options)
                  throws loci.formats.FormatException
Description copied from interface: Codec
Decompresses a block of data.

Specified by:
decompress in interface Codec
Parameters:
input - the data to be decompressed
options - Options to be used during decompression.
Returns:
the decompressed data.
Throws:
loci.formats.FormatException - If data is not valid.