pub fn from_avro_datum<R: Read>(
writer_schema: &Schema,
reader: &mut R,
reader_schema: Option<&Schema>,
) -> AvroResult<Value>๐Deprecated since 0.22.0:
Use GenericDatumReader instead
Expand description
Deprecated.
This is equivalent to
โ
GenericDatumReader::builder(writer_schema)
.maybe_reader_schema(reader_schema)
.build()?
.read_value(reader)Decode a Value encoded in Avro format given its Schema and anything implementing io::Read
to read from.
In case a reader Schema is provided, schema resolution will also be performed.
NOTE This function has a quite small niche of usage and does NOT take care of reading the
header and consecutive data blocks; use Reader if you donโt know what
you are doing, instead.