Package org.apache.avro.generic
package org.apache.avro.generic
A generic representation for Avro data.
This representation is best for applications which deal with dynamic data, whose schemas are not known until runtime.
Avro schemas are mapped to Java types as follows:
- Schema records are implemented as
GenericRecord
. - Schema enums are implemented as
GenericEnumSymbol
. - Schema arrays are implemented as
Collection
. - Schema maps are implemented as
Map
. - Schema fixed are implemented as
GenericFixed
. - Schema strings are implemented as
CharSequence
. - Schema bytes are implemented as
ByteBuffer
. - Schema ints are implemented as
Integer
. - Schema longs are implemented as
Long
. - Schema floats are implemented as
Float
. - Schema doubles are implemented as
Double
. - Schema booleans are implemented as
Boolean
.
-
ClassDescriptionGenericArray<T>Array that permits reuse of contained elements.Contains data of other types.Utilities for generic Java data.Default implementation of an array.Default implementation of
GenericEnumSymbol
.Default implementation ofGenericFixed
.Default implementation ofGenericRecord
.Used to specify the Java type for a string schema.DatumReader
for generic Java objects.DatumWriter
for generic Java objects.GenericEnumSymbol<E extends GenericEnumSymbol<E>>An enum symbol.Fixed-size data.A generic instance of a record schema.A RecordBuilder for generic records.A record implementation that permits field access by integer index.