Interface FieldDecompressor
- All Known Implementing Classes:
BinaryFieldEncoder
,RangeCompressor
public interface FieldDecompressor
All classes capable of decompressing a field must implement this interface
- Version:
- $Revision: 1.4 $
- Author:
- Alan Hudson.
-
Method Summary
Modifier and TypeMethodDescriptionboolean
canSupport
(int fieldType, int method) Can this fieldCompressor support this compression methodboolean
decompressBoolean
(DataInputStream dis, int fieldType) Decompress this field.void
decompressBoolean
(DataInputStream dis, int fieldType, boolean[] data) Decompress this field.double
decompressDouble
(DataInputStream dis, int fieldType) Decompress this field.void
decompressDouble
(DataInputStream dis, int fieldType, double[] data) Decompress this field.void
decompressDouble
(DataInputStream dis, int fieldType, double[][] data) Decompress this field.float
decompressFloat
(DataInputStream dis, int fieldType) Decompress this field.void
decompressFloat
(DataInputStream dis, int fieldType, float[] data) Decompress this field.void
decompressFloat
(DataInputStream dis, int fieldType, float[][] data) Decompress this field.int
decompressInt
(DataInputStream dis, int fieldType) Decompress this field.void
decompressInt
(DataInputStream dis, int fieldType, int[] data) Decompress this field.long
decompressLong
(DataInputStream dis, int fieldType) Decompress this field.void
decompressLong
(DataInputStream dis, int fieldType, long[] data) Decompress this field.decompressString
(DataInputStream dis, int fieldType) Decompress this field.void
decompressString
(DataInputStream dis, int fieldType, String[] data) Decompress this field.int
Get the length of variable length field.
-
Method Details
-
canSupport
boolean canSupport(int fieldType, int method) Can this fieldCompressor support this compression method- Parameters:
fieldType
- What type of field, defined in FieldConstants.method
- What method of compression. 0-127 defined by Web3D Consortium.- Returns:
-
nextLength
Get the length of variable length field.- Parameters:
dis
-- Returns:
- The length of the upcoming field in number of type units.
- Throws:
IOException
-
decompressInt
Decompress this field.- Parameters:
dis
- The stream to read fromfieldType
- The type of field to compress from FieldConstants.- Returns:
- The field value
- Throws:
IOException
-
decompressInt
Decompress this field.- Parameters:
dis
- The stream to read fromfieldType
- The type of field to compress from FieldConstants.data
- The field data, must be preallocated- Throws:
IOException
-
decompressBoolean
Decompress this field.- Parameters:
dis
- The stream to read fromfieldType
- The type of field to compress from FieldConstants.- Returns:
- The field value
- Throws:
IOException
-
decompressBoolean
Decompress this field.- Parameters:
dis
- The stream to read fromfieldType
- The type of field to compress from FieldConstants.data
- The field data, must be preallocated- Throws:
IOException
-
decompressFloat
Decompress this field.- Parameters:
dis
- The stream to read fromfieldType
- The type of field to compress from FieldConstants.- Returns:
- The field value
- Throws:
IOException
-
decompressFloat
Decompress this field.- Parameters:
dis
- The stream to read fromfieldType
- The type of field to compress from FieldConstants.data
- The field data, must be preallocated- Throws:
IOException
-
decompressFloat
Decompress this field.- Parameters:
dis
- The stream to read fromfieldType
- The type of field to compress from FieldConstants.data
- The field data, must be preallocated- Throws:
IOException
-
decompressLong
Decompress this field.- Parameters:
dis
- The stream to read fromfieldType
- The type of field to compress from FieldConstants.- Returns:
- The field value
- Throws:
IOException
-
decompressLong
Decompress this field.- Parameters:
dis
- The stream to read fromfieldType
- The type of field to compress from FieldConstants.data
- The field data, must be preallocated- Throws:
IOException
-
decompressDouble
Decompress this field.- Parameters:
dis
- The stream to read fromfieldType
- The type of field to compress from FieldConstants.- Returns:
- The field value
- Throws:
IOException
-
decompressDouble
Decompress this field.- Parameters:
dis
- The stream to read fromfieldType
- The type of field to compress from FieldConstants.data
- The field data, must be preallocated- Throws:
IOException
-
decompressDouble
Decompress this field.- Parameters:
dis
- The stream to read fromfieldType
- The type of field to compress from FieldConstants.data
- The field data, must be preallocated- Throws:
IOException
-
decompressString
Decompress this field.- Parameters:
dis
- The stream to read fromfieldType
- The type of field to compress from FieldConstants.- Returns:
- The field value
- Throws:
IOException
-
decompressString
Decompress this field.- Parameters:
dis
- The stream to read fromfieldType
- The type of field to compress from FieldConstants.data
- The field data, must be preallocated- Throws:
IOException
-