Class DaffodilXMLEntityResolver

java.lang.Object
org.apache.daffodil.api.DaffodilXMLEntityResolver

public final class DaffodilXMLEntityResolver extends Object
Returns the EntityResolver used by Daffodil to resolve import/include schemaLocations.

The entity resolver attempts to resolve namespaces and systemId's in the following order:

1. Use an org.apache.xml.resolver.Catalog/CatalogManager. By default the Catalog only includes the daffodil-built-in-catalog.xml, but additional catalogs can be added by putting CatalogManager.properties on the classpath when daffodil is run.

2. If not resolved in step 1, schemaLocations are resolved relative to the importing schema URI, which could either be a file on the filesystem or in a jar on the classpath.

The default can be replaced by registering a DaffodilEntityResolverProvider with SPI. The catalogs in step 1 are still consulted first.

  • Method Details

    • getEntityResolver

      public static EntityResolver getEntityResolver()
      Returns:
      entity resolver
    • getXMLEntityResolver

      public static org.apache.xerces.xni.parser.XMLEntityResolver getXMLEntityResolver()
      Returns:
      xml entity resolver
    • getLSResourceResolver

      public static LSResourceResolver getLSResourceResolver()
      Returns:
      ls resource resolver
    • getURIResolver

      public static URIResolver getURIResolver()
      Returns:
      uri resolver