Creates a new Serializer which serializes
all values of type A
as null
.
Creates a new Serializer which serializes
all values of type A
to the specified bytes
.
Creates a new Serializer which delegates serialization
to the specified Kafka Serializer
.
Creates a new Serializer which delegates serialization
to the specified Kafka Serializer
. Note the close
and
configure
functions won't be called for the delegate.
Creates a new Serializer which serializes all
values of type A
as the empty Array[Byte]
.
Creates a new Serializer which can use different Serializers depending on the record headers.
The identity Serializer, which does not perform any kind of serialization, simply using the input bytes as the output.
Creates a new Serializer from the specified function.
Creates a new Serializer from the specified function. Use lift instead if the serializer doesn't need access to the Kafka topic name or record headers.
Creates a new Serializer from the specified function, ignoring to which Kafka topic the bytes are going to be sent and any record headers.
Creates a new Serializer from the specified function, ignoring to which Kafka topic the bytes are going to be sent and any record headers. Use instance instead if the serializer needs access to the Kafka topic name or the record headers.
The option Serializer serializes None
as null
, and
serializes Some
values using the serializer for type A
.
Creates a new Serializer which serializes String
values using the specified Charset
.
Creates a new Serializer which serializes String
values using the specified Charset
. Note that the
default String
serializer uses UTF-8
.
Creates a new Serializer which can use different Serializers depending on the Kafka topic name to which the bytes are going to be sent.
Creates a new Serializer which serializes UUID
values
as String
s with the specified Charset
.
Creates a new Serializer which serializes UUID
values
as String
s with the specified Charset
. Note that the
default UUID
serializer uses UTF-8.