public class GraphBinaryWriter extends Object
Constructor and Description |
---|
GraphBinaryWriter() |
GraphBinaryWriter(TypeSerializerRegistry registry) |
Modifier and Type | Method and Description |
---|---|
ByteBuf |
getValueFlagNone()
Gets a buffer containing a single byte with value 0, representing an unset value_flag.
|
ByteBuf |
getValueFlagNull()
Gets a buffer containing a single byte representing the null value_flag.
|
<T> ByteBuf |
write(T value,
ByteBufAllocator allocator)
Writes an object in fully-qualified format, containing {type_code}{type_info}{value_flag}{value}.
|
<T> ByteBuf |
writeFullyQualifiedNull(Class<T> objectClass,
ByteBufAllocator allocator,
Object information)
Represents a null value of a specific type, useful when the parent type contains a type parameter that must be
specified.
|
<T> ByteBuf |
writeValue(T value,
ByteBufAllocator allocator,
boolean nullable)
Writes a value without including type information.
|
public GraphBinaryWriter()
public GraphBinaryWriter(TypeSerializerRegistry registry)
public <T> ByteBuf writeValue(T value, ByteBufAllocator allocator, boolean nullable) throws SerializationException
SerializationException
public <T> ByteBuf write(T value, ByteBufAllocator allocator) throws SerializationException
SerializationException
public <T> ByteBuf writeFullyQualifiedNull(Class<T> objectClass, ByteBufAllocator allocator, Object information) throws SerializationException
Note that for simple types, the provided information will be null
.
SerializationException
public ByteBuf getValueFlagNull()
public ByteBuf getValueFlagNone()
Copyright © 2013–2019 Apache Software Foundation. All rights reserved.