StateStoreSerializerPBImplpublic abstract class StateStoreSerializer
extends java.lang.Object
| Constructor | Description |
|---|---|
StateStoreSerializer() |
| Modifier and Type | Method | Description |
|---|---|---|
abstract <T extends BaseRecord> |
deserialize(byte[] byteArray,
java.lang.Class<T> clazz) |
Deserialize a bytes array into a record.
|
abstract <T extends BaseRecord> |
deserialize(java.lang.String data,
java.lang.Class<T> clazz) |
Deserialize a string into a record.
|
static StateStoreSerializer |
getSerializer() |
Get the default serializer based.
|
static StateStoreSerializer |
getSerializer(org.apache.hadoop.conf.Configuration conf) |
Get a serializer based on the provided configuration.
|
static <T> T |
newRecord(java.lang.Class<T> clazz) |
Create a new record.
|
abstract <T> T |
newRecordInstance(java.lang.Class<T> clazz) |
Create a new record.
|
abstract byte[] |
serialize(BaseRecord record) |
Serialize a record into a byte array.
|
abstract java.lang.String |
serializeString(BaseRecord record) |
Serialize a record into a string.
|
public static StateStoreSerializer getSerializer()
public static StateStoreSerializer getSerializer(org.apache.hadoop.conf.Configuration conf)
conf - Configuration. Default if null.public static <T> T newRecord(java.lang.Class<T> clazz)
T - Type of the record.clazz - Class of the new record.public abstract <T> T newRecordInstance(java.lang.Class<T> clazz)
T - Type of the record.clazz - Class of the new record.public abstract byte[] serialize(BaseRecord record)
record - Record to serialize.public abstract java.lang.String serializeString(BaseRecord record)
record - Record to serialize.public abstract <T extends BaseRecord> T deserialize(byte[] byteArray, java.lang.Class<T> clazz) throws java.io.IOException
T - Type of the record.byteArray - Byte array to deserialize.clazz - Class of the record.java.io.IOException - If it cannot deserialize the record.public abstract <T extends BaseRecord> T deserialize(java.lang.String data, java.lang.Class<T> clazz) throws java.io.IOException
T - Type of the record.data - String with the data to deserialize.clazz - Class of the record.java.io.IOException - If it cannot deserialize the record.Copyright © 2008–2025 Apache Software Foundation. All rights reserved.