ksassnowski / csv-schema

Parse a CSV file into PHP objects based on a schema.
MIT License
24 stars 3 forks source link

Required Fields #5

Closed gucarletto closed 1 year ago

gucarletto commented 5 years ago

It would be interesting to be able to define in the schema if a field is required or not. For example, if I have a numeric field, and it comes empty, the Parser throws an Exception saying that it is unable to cast empty to int, but that field is not required to have a value.