Module eclipselink

Interface SchemaResolver

  • All Superinterfaces:
    EntityResolver
    All Known Implementing Classes:
    DefaultSchemaResolver

    public interface SchemaResolver
    extends EntityResolver

    Purpose: Interface that can be optionally implemented to resolve imported and included schemas.

    Responsibilities:

    • Given the source schema and namespace and schemaLocation values from an import or include return the referenced Schema
    • Used by XSDHelper define methods and ClassGenerator generate methods
    • Given the publicId and systemId of an external entity, return the file associated with that entity
    See Also:
    DefaultSchemaResolver
    • Method Detail

      • resolveSchema

        Source resolveSchema​(Source sourceXSD,
                             String namespace,
                             String schemaLocation)
        Given the source schema and namespace and schemaLocation values from an import or include return the referenced Schema
        Parameters:
        sourceXSD - The Source object of the source schema
        namespace - The namespace portion of the import/include
        schemaLocation - The schemaLocation portion of the import/include
        Returns:
        Source for the referenced Schema or null if processing the referenced schema should be skipped. If this method throws an exception, processing will stop.