Fixed defaults processing to apply on sub-schemas.
Implemented class definition in sub-schemas.