You are viewing a plain text version of this content. The canonical link for it is here.
Posted to xml-commons-dev@xerces.apache.org by "Michael Glavassevich (JIRA)" <ji...@apache.org> on 2010/12/07 04:39:19 UTC

[jira] Updated: (XMLCOMMONS-73) Find Catalogs using Service Provider Interface

     [ https://issues.apache.org/jira/browse/XMLCOMMONS-73?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Michael Glavassevich updated XMLCOMMONS-73:
-------------------------------------------

    Fix Version/s: XML Commons Resolver 1.2.0

> Find Catalogs using Service Provider Interface
> ----------------------------------------------
>
>                 Key: XMLCOMMONS-73
>                 URL: https://issues.apache.org/jira/browse/XMLCOMMONS-73
>             Project: XmlCommons
>          Issue Type: Improvement
>          Components: XML Commons Resolver (resolver.jar)
>    Affects Versions: 1.x
>         Environment: Operating System: All
> Platform: All
>            Reporter: Martin von Gagern
>            Assignee: Commons Developers Mailing List
>            Priority: Minor
>             Fix For: XML Commons Resolver 1.2.0
>
>
> Developing apps would be greatly simplified if you could simply add some JAR to the classpath, and a Catalog as generated by the default CatalogManager would find the catalog within that JAR as well as the documents it references.
> To achieve this, I believe a slightly modified version of the Service Provider Interface would be most suitable.
> http://java.sun.com/j2se/1.5.0/docs/guide/jar/jar.html#Service%20Provider describes that a file under META-INF/services/package.interface.Name should list qualified names of classes providing said interface.
> To work with XML catalogs, you would specify a class name, but instead the name of a resource. So I think that you should have a file called "META-INF/services/org.apache.xml.resolver.catalog" which would contain lines like "my/company/catalog.xml". That catalog could then be located as a resource, auto-appended to the list of catalogs and parsed along with the system catalogs.
> One could consider placing the catalog itself in the META-INF directory. That, however, would probably prevent it from being uniquely identified by its name alone, which might be useful if you want to deal with the catalog yourself, without using the full CatalogManager framework.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: xml-commons-dev-unsubscribe@xerces.apache.org
For additional commands, e-mail: xml-commons-dev-help@xerces.apache.org