Constructor RecordField
RecordField(string, AvroSchema, JsonElement?, string?, FieldOrder, IEnumerable<string>?, IReadOnlyDictionary<string, JsonElement>?)
Initializes a record field.
public RecordField(string name, AvroSchema schema, JsonElement? defaultValue = null, string? doc = null, FieldOrder order = FieldOrder.Ascending, IEnumerable<string>? aliases = null, IReadOnlyDictionary<string, JsonElement>? properties = null)
Parameters
namestringThe field name; it must be a valid Avro name.
schemaAvroSchemaThe field schema.
defaultValueJsonElement?The JSON default value used during schema resolution, or null for no default. Its form follows the specification's table (for example a string of code points 0-255 for
bytes).docstringOptional documentation.
orderFieldOrderThe sort order.
aliasesIEnumerable<string>Optional alternative names.
propertiesIReadOnlyDictionary<string, JsonElement>Optional custom properties.
Exceptions
- AvroSchemaException
The name is not valid.