public class OnHeapCoder extends Object implements FSTCoder
Modifier and Type | Field and Description |
---|---|
protected byte[] |
buff |
protected FSTConfiguration |
conf |
protected FSTObjectInput |
in |
protected FSTObjectOutput |
out |
protected HeapBytez |
readTarget |
protected HeapBytez |
writeTarget |
Constructor and Description |
---|
OnHeapCoder() |
OnHeapCoder(boolean sharedRefs) |
OnHeapCoder(boolean sharedRefs,
Class... preregister) |
OnHeapCoder(Class... preregister)
throw
|
Modifier and Type | Method and Description |
---|---|
FSTConfiguration |
getConf() |
byte[] |
toByteArray(Object o) |
int |
toByteArray(Object o,
byte[] arr,
int startIndex,
int availableSize)
throws FSTBufferTooSmallExcpetion in case object does not fit into given range
Zero Copy method
|
Object |
toObject(byte[] arr)
decode object into byte array (at position null)
|
Object |
toObject(byte[] arr,
int startIndex,
int availableSize)
throws FSTBufferTooSmallExcpetion in case object does not fit into given range
|
protected FSTConfiguration conf
protected HeapBytez writeTarget
protected HeapBytez readTarget
protected FSTObjectOutput out
protected FSTObjectInput in
protected byte[] buff
public OnHeapCoder()
public OnHeapCoder(boolean sharedRefs)
public OnHeapCoder(Class... preregister)
preregister
- public OnHeapCoder(boolean sharedRefs, Class... preregister)
public int toByteArray(Object o, byte[] arr, int startIndex, int availableSize)
toByteArray
in interface FSTCoder
o
- availableSize
- IOException
public byte[] toByteArray(Object o)
toByteArray
in interface FSTCoder
public FSTConfiguration getConf()
public Object toObject(byte[] arr, int startIndex, int availableSize)
Copyright © 2017. All rights reserved.