Creating a new SAML Object Validator

To implement a Validator create a class that implements the org.opensaml.xml.validation.Validator interface and meets the follow guidelines:

In order to allow other developers to extend validators at a later date we suggest that you do not implement your rules directly within the validate method, but instead create one additional method, per rule, and then simply invoke these rules in the validate method. This allows future developers to override one rule, or add new rules, without having to recreate the whole validator. The org.opensaml.saml2.metadata.validator.EntityDescriptorSchemaValidator class is an example of this approach.