/** * Allow specification of a DTD outside of an XMLCatalog. * * @return a DTDLocation with the specified DTD **/ public DTDLocation createDTD() { DTDLocation dtdLoc = new DTDLocation(); globalXMLCatalog.addEntity(dtdLoc); return dtdLoc; }
/** * Allow specification of an entity outside of an XMLCatalog. * * @return a DTDLocation with the specified entity **/ public DTDLocation createEntity() { DTDLocation dtdLoc = new DTDLocation(); globalXMLCatalog.addEntity(dtdLoc); return dtdLoc; }
/** * @see org.eclipse.wst.wsdl.validation.internal.xml.XMLCatalog#addEntryToCatalog(java.lang.String, java.lang.String) */ public void addEntryToCatalog(String publicId, String systemId) { DTDLocation resLoc = new DTDLocation(); resLoc.setLocation(systemId); resLoc.setPublicId(publicId); xmlCatalog.addEntity(resLoc); }
/** * <p>Add a URI catalog entry to the controlling XMLCatalog instance. * ApacheCatalog calls this for each URI entry found in an external * catalog file.</p> * * @param uri The URI of the resource * @param altURI The URI to which the resource should be mapped * (aka the location) * @param base The base URL of the resource. If the altURI * specifies a relative URL/pathname, it is resolved using the * base. The default base for an external catalog file is the * directory in which the catalog is located. * */ public void addURIEntry(final String uri, final String altURI, final URL base) { final ResourceLocation entity = new ResourceLocation(); entity.setBase(base); entity.setPublicId(uri); entity.setLocation(altURI); xmlCatalog.addEntity(entity); }