Constructor and Description |
---|
MultiCodec(Map<Class<? extends T>,Codec<? extends T>> clazzToCodecMap)
Constructs a codec that encodes/decodes an object to/from bytes based on the class name.
|
Modifier and Type | Method and Description |
---|---|
T |
decode(byte[] data)
Decodes byte array.
|
byte[] |
encode(T obj)
Encodes an object to a byte array.
|
Copyright © 2016 The Apache Software Foundation. All rights reserved.