| Modifier and Type | Class and 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 and Description |
|---|---|
static Codec |
DEFAULT_CODEC
A singleton instance of a
Codecs.DefaultCodec |
| Constructor and Description |
|---|
Codecs() |
| Modifier and Type | Method and Description |
|---|---|
static Codec |
getCodec(Class<?> clz)
Return a
Codec based on the provided Class. |
public static final Codec DEFAULT_CODEC
Codecs.DefaultCodecpublic 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