|Re: Programmatically do XML Catalog contributions in WST [message #204685 is a reply to message #204473]
||Mon, 19 November 2007 08:32
| Anders Olsson
Registered: July 2009
Thank you for your reply, Lawrence.|
I've tried implementing this solution in my plug-in, but I've ran into
What I've done is that I've added an extension:
in my plug-in.
The schemaSetter.ResolverExtension1 class is very simple, and implements
in both the resolve and resolvePhysicalLocation methods I simply return a
URI string without checking the input arguments.
I would paste the code, but so far that's not where the problem lies. I
ran in debugging mode with break points in both the methods, and they were
never visited. What I tried to do is to validate an XML file, but all I
get is an error about <the original URI> not being found.
Is there something I've missed? Is there something more that needs to be
done to use this resource?
> Hi Anders,
> If your contributed DTDs don't need to be viewable in the XML catalog you
> can create a custom URI resolver .
http://help.eclipse.org/help31/topic/org.eclipse.wst.doc.isv /reference/extension-points/common/org_eclipse_wst_common_ur iresolver_resolverExtensions.html
>>I have a need for adding DTDs to the XML Catalog in WST. I cannot use the
>>org.eclipse.est.xml.core.catalogContributions Extension Point, since the
>>location of the DTDs might be different every startup (or on different
>>I've been looking at the internal classes in
>>org.eclipse.wst.xml.core.internal and .catalog to little avail. I've
>>managed to do:
>>XMLCorePlugin xmlPlug =
>> org.eclipse.wst.xml.core.internal.XMLCorePlugin.getDefault() ;
>>Catalog defaultXMLCatalog = (Catalog) xmlPlug.getDefaultXMLCatalog();
>>What I then should do is a bit unclear. I want to do is add entries one
>>one. So I think the class I should instance and insert is CatalogEntry.
>>Problem is only it has it's constructor set as protected.
>>What I would of course want is a public API for XML Catalog
>>But for now I'm content with using the internals. Could someone tell me
>>my approach makes sense, and where I've diverted from the correct path.
>>cannot be the case that this is currently impossible.
>>Thanks in advance for any replies.
Powered by FUDForum
. Page generated in 0.02098 seconds