Interface ExtendedDeserializer<T>
-
- Type Parameters:
T
-
- All Superinterfaces:
AutoCloseable
,Closeable
,Deserializer<T>
- All Known Implementing Classes:
ExtendedDeserializer.Wrapper
@Deprecated public interface ExtendedDeserializer<T> extends Deserializer<T>
Deprecated.This class has been deprecated and will be removed in a future release. Please useDeserializer
instead.A Deserializer that has access to the headers associated with the record. PreferDeserializer
if access to the headers is not required. Once Kafka drops support for Java 7, thedeserialize()
method introduced by this interface will be added to Deserializer with a default implementation so that backwards compatibility is maintained. This interface may be deprecated once that happens. A class that implements this interface is expected to have a constructor with no parameters.
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static class
ExtendedDeserializer.Wrapper<T>
Deprecated.
-
Method Summary
All Methods Instance Methods Abstract Methods Deprecated Methods Modifier and Type Method Description T
deserialize(String topic, Headers headers, byte[] data)
Deprecated.Deserialize a record value from a byte array into a value or object.-
Methods inherited from interface org.apache.kafka.common.serialization.Deserializer
close, configure, deserialize
-
-
-
-
Method Detail
-
deserialize
T deserialize(String topic, Headers headers, byte[] data)
Deprecated.Deserialize a record value from a byte array into a value or object.- Specified by:
deserialize
in interfaceDeserializer<T>
- Parameters:
topic
- topic associated with the dataheaders
- headers associated with the record; may be empty.data
- serialized bytes; may be null; implementations are recommended to handle null by returning a value or null rather than throwing an exception.- Returns:
- deserialized typed data; may be null
-
-