use Classes not functions in the schemas, for improved validation failur...

...e messages