Package org.apache.kafka.streams.state
Class Stores.ValueFactory<K>
- java.lang.Object
-
- org.apache.kafka.streams.state.Stores.ValueFactory<K>
-
- Type Parameters:
K- the type of keys
- Enclosing class:
- Stores
public abstract static class Stores.ValueFactory<K> extends java.lang.ObjectThe factory for creating off-heap key-value stores.
-
-
Constructor Summary
Constructors Constructor Description ValueFactory()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description Stores.KeyValueFactory<K,byte[]>withByteArrayValues()Use byte arrays for values.Stores.KeyValueFactory<K,java.nio.ByteBuffer>withByteBufferValues()UseByteBufferfor values.Stores.KeyValueFactory<K,java.lang.Double>withDoubleValues()UseDoublevalues.Stores.KeyValueFactory<K,java.lang.Integer>withIntegerValues()UseIntegervalues.Stores.KeyValueFactory<K,java.lang.Long>withLongValues()UseLongvalues.Stores.KeyValueFactory<K,java.lang.String>withStringValues()UseStringvalues.<V> Stores.KeyValueFactory<K,V>withValues(java.lang.Class<V> valueClass)Use values of the specified type.abstract <V> Stores.KeyValueFactory<K,V>withValues(org.apache.kafka.common.serialization.Serde<V> valueSerde)Use the specified serializer and deserializer for the values.
-
-
-
Method Detail
-
withStringValues
public Stores.KeyValueFactory<K,java.lang.String> withStringValues()
UseStringvalues.- Returns:
- the interface used to specify the remaining key-value store options; never null
-
withIntegerValues
public Stores.KeyValueFactory<K,java.lang.Integer> withIntegerValues()
UseIntegervalues.- Returns:
- the interface used to specify the remaining key-value store options; never null
-
withLongValues
public Stores.KeyValueFactory<K,java.lang.Long> withLongValues()
UseLongvalues.- Returns:
- the interface used to specify the remaining key-value store options; never null
-
withDoubleValues
public Stores.KeyValueFactory<K,java.lang.Double> withDoubleValues()
UseDoublevalues.- Returns:
- the interface used to specify the remaining key-value store options; never null
-
withByteBufferValues
public Stores.KeyValueFactory<K,java.nio.ByteBuffer> withByteBufferValues()
UseByteBufferfor values.- Returns:
- the interface used to specify the remaining key-value store options; never null
-
withByteArrayValues
public Stores.KeyValueFactory<K,byte[]> withByteArrayValues()
Use byte arrays for values.- Returns:
- the interface used to specify the remaining key-value store options; never null
-
withValues
public <V> Stores.KeyValueFactory<K,V> withValues(java.lang.Class<V> valueClass)
Use values of the specified type.- Parameters:
valueClass- the class for the values, which must be one of the types for which Kafka has built-in serdes- Returns:
- the interface used to specify the remaining key-value store options; never null
-
withValues
public abstract <V> Stores.KeyValueFactory<K,V> withValues(org.apache.kafka.common.serialization.Serde<V> valueSerde)
Use the specified serializer and deserializer for the values.- Parameters:
valueSerde- the serialization factory for values; may be null- Returns:
- the interface used to specify the remaining key-value store options; never null
-
-