T - type of record it producespublic class RegistryAvroDeserializationSchema<T> extends AvroDeserializationSchema<T>
SchemaCoder.| Constructor and Description |
|---|
RegistryAvroDeserializationSchema(Class<T> recordClazz,
org.apache.avro.Schema reader,
SchemaCoder.SchemaCoderProvider schemaCoderProvider)
Creates Avro deserialization schema that reads schema from input stream using provided
SchemaCoder. |
| Modifier and Type | Method and Description |
|---|---|
T |
deserialize(byte[] message) |
boolean |
equals(Object o) |
int |
hashCode() |
forGeneric, forSpecific, getProducedType, isEndOfStreampublic RegistryAvroDeserializationSchema(Class<T> recordClazz, @Nullable org.apache.avro.Schema reader, SchemaCoder.SchemaCoderProvider schemaCoderProvider)
SchemaCoder.recordClazz - class to which deserialize. Should be either
SpecificRecord or GenericRecord.reader - reader's Avro schema. Should be provided if recordClazz is
GenericRecordschemaCoderProvider - schema provider that allows instantiation of SchemaCoder that will be used for
schema readingpublic T deserialize(byte[] message) throws IOException
deserialize in interface org.apache.flink.api.common.serialization.DeserializationSchema<T>deserialize in class AvroDeserializationSchema<T>IOExceptionpublic boolean equals(Object o)
equals in class AvroDeserializationSchema<T>public int hashCode()
hashCode in class AvroDeserializationSchema<T>Copyright © 2014–2020 The Apache Software Foundation. All rights reserved.