pub fn validate_write(
schema: &ClassSchema,
object: &ParseMap,
) -> Result<SchemaDelta, ParseError>Expand description
Validate a write against a class schema and report what it would add.
Does not mutate. The caller persists the delta only if the write commits, which is the ordering that stops a rejected write from leaving a phantom column behind.
Order of checks per field is upstream’s and is observable, because the first failure is the error the client sees:
- Skip
null, which creates nothing. - If the field exists, the types must agree, else
INCORRECT_TYPE. - Otherwise the name must be legal, and it is an addition.