Table of Contents

Namespace AvroSharp.Generic

Reads and writes Avro data without generated types, as AvroValues, with records as GenericRecord and fixed values as GenericFixed.

The schemas come from AvroSharp.Schemas. The generic overloads of AvroSharp.Containers, AvroSharp.Messages and AvroSharp.Streams (CreateGeneric, OpenGeneric) use these readers and writers.

Classes

AvroValueTransformer

Walks a generic value together with its schema and replaces values inside it: the basis for field-level data rules, encryption and redaction.

GenericDatumJsonReader

Reads the Avro JSON encoding into AvroValues for one schema. Instances are cached per schema and are thread-safe.

GenericDatumJsonWriter

Writes AvroValue data in the Avro JSON encoding for one schema. The schema is compiled once into a tree of typed writer nodes; instances are cached per schema and are thread-safe.

GenericDatumReader

Reads Avro binary data into AvroValues for one schema. The schema is compiled once into a tree of typed reader nodes, so reading does not inspect the schema; instances are cached per schema and are thread-safe.

GenericDatumReaderOptions

Limits that protect GenericDatumReader against malformed or hostile input.

GenericDatumWriter

Writes AvroValue data in Avro binary encoding for one schema. The schema is compiled once into a tree of typed writer nodes, so writing does not inspect the schema; instances are cached per schema and are thread-safe.

GenericDatumWriterOptions

Limits for GenericDatumWriter.

GenericFixed

A fixed value in the generic data model: a schema and exactly Size bytes.

GenericRecord

A record in the generic data model: a schema and one AvroValue per field.

Structs

AvroFieldContext

Where a value handed to an AvroFieldTransform is: the record field, and the value's schema.

AvroValue

Any Avro value in the generic data model, without boxing: primitives are stored inline, and strings, bytes, records, enums, arrays, maps and fixed values by reference.

Enums

AvroValueKind

The kind of value held by an AvroValue.

Delegates

AvroFieldTransform

Replaces a value found inside a record field. Receives the field it is in and the value; returns the value to keep, which may be the same one.