adds validation of required attributes
Merge pull request #12 from jpstroop/require_attributes

adds validation of required attributes