Modifier and Type | Class | Description |
---|---|---|
static class |
Codecs.AbstractCodec |
Abstract
Codec implementations that encodes objects by simply
delegating to PofWriter.writeObject(int, Object) . |
static class |
Codecs.ArrayCodec |
Implementation of
Codec that delegates to
PofReader.readObjectArray(int, Object[]) and
PofWriter.writeObjectArray(int, Object[]) to deserialize and serialize
an object. |
static class |
Codecs.CollectionCodec |
Implementation of
Codec that delegates to
PofReader.readCollection(int, Collection) and
PofWriter.writeCollection(int, Collection) to deserialize and
serialize an object. |
static class |
Codecs.DefaultCodec |
Implementation of
Codec that simply delegates to
PofReader.readObject(int) and
PofWriter.writeObject(int, Object) to deserialize and serialize
an object. |
static class |
Codecs.LongArrayCodec |
Implementation of
Codec that delegates to
PofReader.readLongArray(int, LongArray) and
PofWriter.writeLongArray(int, LongArray) to deserialize and serialize
an object. |
static class |
Codecs.MapCodec |
Implementation of
Codec that delegates to
PofReader.readMap(int, Map) and
PofWriter.writeMap(int, Map) to deserialize and serialize
an object. |
Modifier and Type | Field | Description |
---|---|---|
static Codec |
DEFAULT_CODEC |
A singleton instance of a
Codecs.DefaultCodec |
Constructor | Description |
---|---|
Codecs() |
Modifier and Type | Method | Description |
---|---|---|
static Codec |
getCodec(Class<?> clz) |
Return a
Codec based on the provided Class. |
public static final Codec DEFAULT_CODEC
Codecs.DefaultCodec
public static Codec getCodec(Class<?> clz)
Codec
based on the provided Class.
The provided Class should implement one of:
Collection
interface and have a no-arg constructor. A Codec
supporting Collections will be returnedMap
interface
and have a no-arg constructor. A Codec supporting Maps
will be returnedLongArray
interface
and have a no-arg constructor. A Codec supporting LongArrays
will be returnedclz
- a Class that implements Codec or is one of the supported
types