Package com.ardor3d.util.export.binary
Class BinaryOutputCapsule
java.lang.Object
com.ardor3d.util.export.binary.BinaryOutputCapsule
- All Implemented Interfaces:
OutputCapsule
-
Field Summary
Modifier and TypeFieldDescriptionprotected ByteArrayOutputStream
protected byte[]
protected BinaryClassObject
protected BinaryExporter
protected boolean
static byte[]
static final int
static byte[]
static final int
-
Constructor Summary
ConstructorDescriptionBinaryOutputCapsule
(BinaryExporter exporter, BinaryClassObject bco) BinaryOutputCapsule
(BinaryExporter exporter, BinaryClassObject bco, boolean forceDirectNioBuffers) -
Method Summary
Modifier and TypeMethodDescriptionprotected static byte[]
deflate
(byte[] bytes) boolean
void
finish()
protected void
generateAlias
(String name, byte type) int
hashCode()
protected void
write
(boolean value) protected void
write
(boolean[] value) protected void
write
(boolean[][] value) void
void
void
protected void
write
(byte value) protected void
write
(byte[] value) protected void
write
(byte[][] value) void
void
void
protected void
write
(double value) protected void
write
(double[] value) protected void
write
(double[][] value) void
void
void
protected void
write
(float value) protected void
write
(float[] value) protected void
write
(float[][] value) void
void
void
protected void
write
(int value) protected void
write
(int[] value) protected void
write
(int[][] value) void
void
void
protected void
write
(long value) protected void
write
(long[] value) protected void
write
(long[][] value) void
void
void
protected void
write
(short value) protected void
write
(short[] value) protected void
write
(short[][] value) void
void
void
protected void
protected void
protected void
void
void
void
void
void
protected void
protected void
protected void
void
void
void
protected void
write
(ByteBuffer source) void
write
(ByteBuffer value, String name, ByteBuffer defVal) protected void
write
(FloatBuffer source) void
write
(FloatBuffer value, String name, FloatBuffer defVal) protected void
void
protected void
write
(ShortBuffer source) void
write
(ShortBuffer value, String name, ShortBuffer defVal) protected void
void
protected void
writeAlias
(String name, byte fieldType) protected void
writeByteBufferArrayList
(List<ByteBuffer> array) void
writeByteBufferList
(List<ByteBuffer> array, String name, List<ByteBuffer> defVal) protected void
writeFloatBufferArrayList
(List<FloatBuffer> array) void
writeFloatBufferList
(List<FloatBuffer> array, String name, List<FloatBuffer> defVal) protected void
writeSavableArrayList
(List<? extends Savable> array) protected void
writeSavableArrayListArray
(List<? extends Savable>[] array) protected void
writeSavableArrayListArray2D
(List<? extends Savable>[][] array) void
void
writeSavableListArray
(List<? extends Savable>[] array, String name, List<? extends Savable>[] defVal) void
writeSavableListArray2D
(List<? extends Savable>[][] array, String name, List<? extends Savable>[][] defVal) protected void
writeSavableMap
(Map<? extends Savable, ? extends Savable> array) void
writeSavableMap
(Map<? extends Savable, ? extends Savable> map, String name, Map<? extends Savable, ? extends Savable> defVal) protected void
writeStringSavableMap
(Map<String, ? extends Savable> array) void
writeStringSavableMap
(Map<String, ? extends Savable> map, String name, Map<String, ? extends Savable> defVal)
-
Field Details
-
NULL_OBJECT
public static final int NULL_OBJECT- See Also:
-
DEFAULT_OBJECT
public static final int DEFAULT_OBJECT- See Also:
-
NULL_BYTES
public static byte[] NULL_BYTES -
DEFAULT_BYTES
public static byte[] DEFAULT_BYTES -
_baos
-
_bytes
protected byte[] _bytes -
_exporter
-
_cObj
-
_forceDirectNioBuffers
protected boolean _forceDirectNioBuffers
-
-
Constructor Details
-
BinaryOutputCapsule
-
BinaryOutputCapsule
public BinaryOutputCapsule(BinaryExporter exporter, BinaryClassObject bco, boolean forceDirectNioBuffers)
-
-
Method Details
-
write
- Specified by:
write
in interfaceOutputCapsule
- Throws:
IOException
-
write
- Specified by:
write
in interfaceOutputCapsule
- Throws:
IOException
-
write
- Specified by:
write
in interfaceOutputCapsule
- Throws:
IOException
-
write
- Specified by:
write
in interfaceOutputCapsule
- Throws:
IOException
-
write
- Specified by:
write
in interfaceOutputCapsule
- Throws:
IOException
-
write
- Specified by:
write
in interfaceOutputCapsule
- Throws:
IOException
-
write
- Specified by:
write
in interfaceOutputCapsule
- Throws:
IOException
-
write
- Specified by:
write
in interfaceOutputCapsule
- Throws:
IOException
-
write
- Specified by:
write
in interfaceOutputCapsule
- Throws:
IOException
-
write
- Specified by:
write
in interfaceOutputCapsule
- Throws:
IOException
-
write
- Specified by:
write
in interfaceOutputCapsule
- Throws:
IOException
-
write
- Specified by:
write
in interfaceOutputCapsule
- Throws:
IOException
-
write
- Specified by:
write
in interfaceOutputCapsule
- Throws:
IOException
-
write
- Specified by:
write
in interfaceOutputCapsule
- Throws:
IOException
-
write
- Specified by:
write
in interfaceOutputCapsule
- Throws:
IOException
-
write
- Specified by:
write
in interfaceOutputCapsule
- Throws:
IOException
-
write
- Specified by:
write
in interfaceOutputCapsule
- Throws:
IOException
-
write
- Specified by:
write
in interfaceOutputCapsule
- Throws:
IOException
-
write
- Specified by:
write
in interfaceOutputCapsule
- Throws:
IOException
-
write
- Specified by:
write
in interfaceOutputCapsule
- Throws:
IOException
-
write
- Specified by:
write
in interfaceOutputCapsule
- Throws:
IOException
-
write
- Specified by:
write
in interfaceOutputCapsule
- Throws:
IOException
-
write
- Specified by:
write
in interfaceOutputCapsule
- Throws:
IOException
-
write
- Specified by:
write
in interfaceOutputCapsule
- Throws:
IOException
-
write
- Specified by:
write
in interfaceOutputCapsule
- Throws:
IOException
-
write
- Specified by:
write
in interfaceOutputCapsule
- Throws:
IOException
-
write
- Specified by:
write
in interfaceOutputCapsule
- Throws:
IOException
-
write
- Specified by:
write
in interfaceOutputCapsule
- Throws:
IOException
-
write
- Specified by:
write
in interfaceOutputCapsule
- Throws:
IOException
-
write
- Specified by:
write
in interfaceOutputCapsule
- Throws:
IOException
-
write
- Specified by:
write
in interfaceOutputCapsule
- Throws:
IOException
-
write
- Specified by:
write
in interfaceOutputCapsule
- Throws:
IOException
-
writeFloatBufferList
public void writeFloatBufferList(List<FloatBuffer> array, String name, List<FloatBuffer> defVal) throws IOException - Specified by:
writeFloatBufferList
in interfaceOutputCapsule
- Throws:
IOException
-
writeByteBufferList
public void writeByteBufferList(List<ByteBuffer> array, String name, List<ByteBuffer> defVal) throws IOException - Specified by:
writeByteBufferList
in interfaceOutputCapsule
- Throws:
IOException
-
writeSavableList
public void writeSavableList(List<? extends Savable> array, String name, List<? extends Savable> defVal) throws IOException - Specified by:
writeSavableList
in interfaceOutputCapsule
- Throws:
IOException
-
writeSavableListArray
public void writeSavableListArray(List<? extends Savable>[] array, String name, List<? extends Savable>[] defVal) throws IOException - Specified by:
writeSavableListArray
in interfaceOutputCapsule
- Throws:
IOException
-
writeSavableListArray2D
public void writeSavableListArray2D(List<? extends Savable>[][] array, String name, List<? extends Savable>[][] defVal) throws IOException - Specified by:
writeSavableListArray2D
in interfaceOutputCapsule
- Throws:
IOException
-
writeSavableMap
public void writeSavableMap(Map<? extends Savable, ? extends Savable> map, String name, Map<? extends Savable, throws IOException? extends Savable> defVal) - Specified by:
writeSavableMap
in interfaceOutputCapsule
- Throws:
IOException
-
writeStringSavableMap
public void writeStringSavableMap(Map<String, ? extends Savable> map, String name, Map<String, throws IOException? extends Savable> defVal) - Specified by:
writeStringSavableMap
in interfaceOutputCapsule
- Throws:
IOException
-
writeAlias
- Throws:
IOException
-
generateAlias
-
equals
-
hashCode
public int hashCode() -
finish
public void finish() -
write
- Throws:
IOException
-
write
- Throws:
IOException
-
write
- Throws:
IOException
-
write
- Throws:
IOException
-
write
- Throws:
IOException
-
write
- Throws:
IOException
-
write
- Throws:
IOException
-
write
- Throws:
IOException
-
write
- Throws:
IOException
-
write
- Throws:
IOException
-
write
- Throws:
IOException
-
write
- Throws:
IOException
-
write
- Throws:
IOException
-
write
- Throws:
IOException
-
write
- Throws:
IOException
-
write
- Throws:
IOException
-
write
- Throws:
IOException
-
write
- Throws:
IOException
-
write
- Throws:
IOException
-
write
- Throws:
IOException
-
write
- Throws:
IOException
-
write
- Throws:
IOException
-
write
- Throws:
IOException
-
write
- Throws:
IOException
-
write
- Throws:
IOException
-
deflate
protected static byte[] deflate(byte[] bytes) -
write
- Throws:
IOException
-
write
- Throws:
IOException
-
write
- Throws:
IOException
-
writeSavableArrayList
- Throws:
IOException
-
writeSavableArrayListArray
- Throws:
IOException
-
writeSavableArrayListArray2D
- Throws:
IOException
-
writeSavableMap
- Throws:
IOException
-
writeStringSavableMap
- Throws:
IOException
-
writeFloatBufferArrayList
- Throws:
IOException
-
writeByteBufferArrayList
- Throws:
IOException
-
write
- Throws:
IOException
-
write
- Throws:
IOException
-
write
- Throws:
IOException
-
write
- Throws:
IOException
-
write
- Specified by:
write
in interfaceOutputCapsule
- Throws:
IOException
-
write
- Specified by:
write
in interfaceOutputCapsule
- Throws:
IOException
-