Class RestMessageValidator

java.lang.Object
com.aquima.interactions.communication.impl.validator.RestMessageValidator

public final class RestMessageValidator extends Object
Class that can be used to validate a rest message.
Since:
9.0
Author:
Jon van Leuven
  • Constructor Details

    • RestMessageValidator

      public RestMessageValidator(IRestMessageDefinition message, ISchemaSetDefinition schemaSet, ISchemaContract contract)
      Construct a rest message validator for a message definition, schema set and contract definition.
      Parameters:
      message - The message definition, may not be null.
      schemaSet - The schema set defintion, may not be null.
      contract - The contract definition, may not be null.
  • Method Details

    • validate

      public void validate(String xml)
      This method may be used to validate the provided xml.
      Parameters:
      xml - The xml, may not be null or empty.
      Throws:
      XmlValidationException - Is thrown when the xml does not validate against the definition(s).