Class XsdSchemaImpl

java.lang.Object
net.sf.saxon.s9api.XsdSchema
com.saxonica.ee.s9api.XsdSchemaImpl

public class XsdSchemaImpl extends XsdSchema
  • Method Details

    • newValidator

      public SchemaValidator newValidator()
      Create a SchemaValidator which can be used to validate instance documents against this schema
      Specified by:
      newValidator in class XsdSchema
      Returns:
      a new SchemaValidator
      Since:
      13.0
    • newItemTypeFactory

      public ItemTypeFactory newItemTypeFactory()
      Create an ItemTypeFactory which can be used to create ItemType objects based on the definitions in this schema.
      Specified by:
      newItemTypeFactory in class XsdSchema
      Returns:
      an ItemTypeFactory linked to this schema.
    • combine

      public XsdSchema combine(XsdSchema other) throws SaxonApiException
      Combine this schema with another, to form a new combined schema.

      Note: in relatively unusual circumstances, a document that is valid against one of the two input schemas might not be valid against the combined schema. For example, if the first schema has a wildcard with processContents="lax" then an element might be laxly validated when assessed using that schema, but strictly validated when assessed against the combined schema; and strict validation may fail while lax validation succeeded.

      Specified by:
      combine in class XsdSchema
      Parameters:
      other - the other schema to combine with this one.
      Returns:
      the combined schema, assuming the two schemas are compatible
      Throws:
      SaxonApiException - if the two schemas cannot be combined, for example because they contain components with duplicated names
      Since:
      13.0
    • getUnderlyingSchema

      public Schema getUnderlyingSchema()
      Get the underlying implementation-level Schema
      Specified by:
      getUnderlyingSchema in class XsdSchema
    • exportComponents

      public void exportComponents(Destination destination) throws SaxonApiException
      Export a precompiled Schema Component Model containing all the components (except built-in components) that have been loaded into this Processor.
      Specified by:
      exportComponents in class XsdSchema
      Parameters:
      destination - the destination to recieve the precompiled Schema Component Model in the form of an XML document
      Throws:
      SaxonApiException - if a failure occurs writing the schema components to the supplied destination