|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectedu.ucsb.nceas.metacat.DBEntityResolver
A database aware Class implementing EntityResolver interface for the SAX parser to call when processing the XML stream and intercepting any external entities (including the external DTD subset and external parameter entities, if any) before including them.
Constructor Summary | |
DBEntityResolver(DBConnection conn)
Construct an instance of the DBEntityResolver class |
|
DBEntityResolver(DBConnection conn,
org.xml.sax.helpers.DefaultHandler handler,
java.io.Reader dtd)
Construct an instance of the DBEntityResolver class |
Method Summary | |
static java.io.InputStream |
checkURLConnection(java.lang.String systemId)
Check URL Connection for @systemId, and return an InputStream that can be used to read from the systemId URL. |
static java.lang.String |
getDTDSystemID(java.lang.String doctype)
Look at db XML Catalog to get System ID (if any) for @doctype. |
org.xml.sax.InputSource |
resolveEntity(java.lang.String publicId,
java.lang.String systemId)
The Parser call this method before opening any external entity except the top-level document entity (including the external DTD subset, external entities referenced within the DTD, and external entities referenced within the document element) |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public DBEntityResolver(DBConnection conn)
conn
- the JDBC connection to which information is writtenpublic DBEntityResolver(DBConnection conn, org.xml.sax.helpers.DefaultHandler handler, java.io.Reader dtd)
conn
- the JDBC connection to which information is writtenhandler
- the SAX handler to determine parsing contextdtd
- Reader of new dtd to be uploaded on server's file systemMethod Detail |
public org.xml.sax.InputSource resolveEntity(java.lang.String publicId, java.lang.String systemId) throws org.xml.sax.SAXException
resolveEntity
in interface org.xml.sax.EntityResolver
org.xml.sax.SAXException
public static java.lang.String getDTDSystemID(java.lang.String doctype) throws org.xml.sax.SAXException
org.xml.sax.SAXException
public static java.io.InputStream checkURLConnection(java.lang.String systemId) throws org.xml.sax.SAXException
systemId
- a URI (in practice URL) to be checked and opened
org.xml.sax.SAXException
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |