enum FieldPlan {
Scalar,
Struct {
bindings: Vec<FieldBinding>,
},
List {
items_nullability: Option<Nullability>,
item_plan: Box<FieldPlan>,
},
Decimal {
size: Option<usize>,
},
Uuid,
Map {
values_nullability: Option<Nullability>,
value_plan: Box<FieldPlan>,
},
Enum {
symbols: Arc<[String]>,
},
Union {
bindings: Vec<FieldBinding>,
},
RunEndEncoded {
values_nullability: Option<Nullability>,
value_plan: Box<FieldPlan>,
},
Duration,
TimeMillisFromSecs,
}Expand description
Per‑site encoder plan for a field. This mirrors the Avro structure, so nested optional branch order can be honored exactly as declared by the schema.
Variants§
Scalar
Non-nested scalar/logical type
Struct
Record/Struct with Avro‑ordered children
Fields
bindings: Vec<FieldBinding>List
Array with item‑site nullability and nested plan
Decimal
Avro decimal logical type (bytes or fixed). size=None => bytes(decimal), Some(n) => fixed(n)
Uuid
Avro UUID logical type (fixed)
Map
Avro map with value‑site nullability and nested plan
Enum
Avro enum; maps to Arrow Dictionary<Int32, Utf8> with dictionary values
exactly equal and ordered as the Avro enum symbols.
Union
Avro union, maps to Arrow Union.
Fields
bindings: Vec<FieldBinding>RunEndEncoded
Avro RunEndEncoded site. Values are encoded per logical row by mapping the
row index to its containing run and emitting that run’s value with value_plan.
Duration
Standard Avro duration logical type (fixed(12), three LE u32 values).
Used when Codec::Interval is resolved, ensuring the 12-byte duration encoder
is selected regardless of the avro_custom_types feature flag.
TimeMillisFromSecs
Arrow Time32(Second) mapped to Avro time-millis — values must be scaled × 1000.
Used when Codec::TimeMillis is resolved for a Time32(Second) Arrow column,
ensuring the scaling encoder is selected regardless of the avro_custom_types feature flag.