public class GuaguaWritableSerializer<RESULT extends Bytable> extends BytableSerializer<RESULT>
GuaguaWritableSerializer is to provide the functionality to support use hadoop writable interface.
By using this, one should set result class name to Writable, not Bytable like this:
conf.set(GuaguaConstants.GUAGUA_RESULT_CLASS, LongWritable.class.getName());
| Constructor and Description |
|---|
GuaguaWritableSerializer()
Deprecated.
|
| Modifier and Type | Method and Description |
|---|---|
RESULT |
bytesToObject(byte[] data,
String className)
Deprecated.
De-serialize from bytes to object.
|
objectToBytespublic RESULT bytesToObject(byte[] data, String className)
bytesToObject in interface Serializer<RESULT extends Bytable>bytesToObject in class BytableSerializer<RESULT extends Bytable>NullPointerException - if className or data is null.GuaguaRuntimeException - if any io exception.Copyright © 2018. All Rights Reserved.