domain validation

This adds validations to domain model.

This depends on #1!