public class ZkStringSerializer extends Object implements org.I0Itec.zkclient.serialize.ZkSerializer
serializer
that is compatible with the
ZooKeeper command line client (ZkCli).
Note: All text encoding/decoding is done as UTF-8.Constructor and Description |
---|
ZkStringSerializer() |
public byte[] serialize(Object data) throws org.I0Itec.zkclient.exception.ZkMarshallingError
serialize
in interface org.I0Itec.zkclient.serialize.ZkSerializer
data
- String dataorg.I0Itec.zkclient.exception.ZkMarshallingError
public Object deserialize(byte[] bytes) throws org.I0Itec.zkclient.exception.ZkMarshallingError
deserialize
in interface org.I0Itec.zkclient.serialize.ZkSerializer
bytes
- the UTF-8 byte representation of a String.org.I0Itec.zkclient.exception.ZkMarshallingError
Copyright © 2012. All Rights Reserved.