Class AbstractXmlValidator

  • Direct Known Subclasses:
    XJdfValidator

    public abstract class AbstractXmlValidator
    extends java.lang.Object
    Abstract Validation of XML Documents based on XSD schema file.
    • Constructor Summary

      Constructors 
      Constructor Description
      AbstractXmlValidator​(java.util.Map<java.lang.String,​byte[]> xsdDependencies)
      Custom constructor.
    • Method Summary

      All Methods Instance Methods Abstract Methods Concrete Methods 
      Modifier and Type Method Description
      protected abstract java.net.URL getSchema()
      Get the URL of the schema to validate against.
      void validate​(java.io.InputStream documentStream)
      Validation of XJDF Document based on XJDF Schema.
      protected void validate​(javax.xml.transform.Source source)
      Validation of XJDF Document based on XJDF Schema.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • AbstractXmlValidator

        public AbstractXmlValidator​(java.util.Map<java.lang.String,​byte[]> xsdDependencies)
        Custom constructor.
        Parameters:
        xsdDependencies - Dependencies for the XSD.
    • Method Detail

      • validate

        public final void validate​(java.io.InputStream documentStream)
                            throws jakarta.xml.bind.ValidationException
        Validation of XJDF Document based on XJDF Schema.
        Parameters:
        documentStream - Stream to read document from.
        Throws:
        jakarta.xml.bind.ValidationException - Is thrown in case the underlying document is invalid.
      • validate

        protected final void validate​(javax.xml.transform.Source source)
                               throws jakarta.xml.bind.ValidationException
        Validation of XJDF Document based on XJDF Schema.
        Parameters:
        source - XML source to validate
        Throws:
        jakarta.xml.bind.ValidationException - Is thrown in case the underlying document is invalid.
      • getSchema

        protected abstract java.net.URL getSchema()
        Get the URL of the schema to validate against.
        Returns:
        Internal URL to of the schema.