Resource validation with jsonschema

Resource can now be validated with jsonschema by defining SCHEMA class
property on reource class.