Method TryValidate
TryValidate(in AvroValue, out string?)
Checks that a value can be written with Schema, as Validate(in AvroValue) does, without throwing.
public bool TryValidate(in AvroValue value, out string? error)
Parameters
valueAvroValueThe value.
errorstringWhy the value can't be written, naming the field, when this method returns false.
Returns
- bool
Whether the value can be written.