Class XMLFileAssociationResolverExtension

    • Constructor Detail

      • XMLFileAssociationResolverExtension

        public XMLFileAssociationResolverExtension()
    • Method Detail

      • setFileAssociations

        public boolean setFileAssociations​(XMLFileAssociation[] fileAssociations)
        Parameters:
        fileAssociations -
        Returns:
        true if file associations changed and false otherwise
      • resolve

        public String resolve​(String baseLocation,
                              String publicId,
                              String systemId)
        Specified by:
        resolve in interface URIResolverExtension
        Parameters:
        baseLocation - - the location of the resource that contains the uri
        publicId - - an optional public identifier (i.e. namespace name), or null if none
        systemId - - an absolute or relative URI, or null if none
        Returns:
        an absolute URI representation of the 'logical' location of the resource
      • getExternalGrammarLocation

        public Map<String,​String> getExternalGrammarLocation​(URI fileURI)
        Description copied from interface: IExternalGrammarLocationProvider
        Provided the file path URI, this will return the external schema location. The schema location is associated to a specific property, which serves as the key in the map. The supported properties are:

        http://apache.org/xml/properties/schema/external-schemaLocation - The value for this property follows the same rules as the schemaLocation attribute for an XML document (i.e., multiple schemas are acceptable and must be white-space separated).

        http://apache.org/xml/properties/schema/external-noNamespaceSchemaLocation - The value for this property follows the same rules as the noNamespaceSchemaLocation attribute for an XML document (i.e., only one schema is allowed).

        Specified by:
        getExternalGrammarLocation in interface IExternalGrammarLocationProvider
        Returns:
        a Map associating the external-schemaLocation and/or external-noNamespaceSchemaLocation to the schema location
      • setRootUri

        public void setRootUri​(String rootUri)
        Set the root URI
        Parameters:
        rootUri - the root URI