Class BlastXMLParserFacade
java.lang.Object
org.biojava.bio.program.sax.blastxml.BlastXMLParserFacade
- All Implemented Interfaces:
XMLReader
A facade class that wraps the NCBI Blast XML
parsing framework in a more user-friendly form.
It is identical to BlastlikeSAXParser in use.
- Since:
- 1.3
- Author:
- David Huen
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncorrect this laterThis class has an EntityResolver that resolves the public ID specifying the NCBI DTDs to resource files within the BioJava libraries.boolean
getFeature
(String name) getProperty
(String name) void
void
parse
(InputSource is) void
setContentHandler
(ContentHandler handler) this sets the ContentHandler that receives SAX events from the internal Blast XML parser which is the actual ContentHandler.void
setDTDHandler
(DTDHandler handler) void
setEntityResolver
(EntityResolver resolver) This class has an EntityResolver that resolves the public ID specifying the NCBI DTDs to resource files within the BioJava libraries.void
setErrorHandler
(ErrorHandler handler) void
setFeature
(String key, boolean value) by default, we set the parser to non-validating.void
setProperty
(String key, Object value)
-
Constructor Details
-
BlastXMLParserFacade
- Throws:
BioException
-
-
Method Details
-
getContentHandler
correct this later- Specified by:
getContentHandler
in interfaceXMLReader
-
getDTDHandler
- Specified by:
getDTDHandler
in interfaceXMLReader
-
getEntityResolver
This class has an EntityResolver that resolves the public ID specifying the NCBI DTDs to resource files within the BioJava libraries. This call will return that resolver. It you should set your own resolver, ensure you resolve that URN yourself or the parser will blow up on you!.- Specified by:
getEntityResolver
in interfaceXMLReader
-
getErrorHandler
- Specified by:
getErrorHandler
in interfaceXMLReader
-
getFeature
- Specified by:
getFeature
in interfaceXMLReader
- Throws:
SAXNotRecognizedException
SAXNotSupportedException
-
getProperty
- Specified by:
getProperty
in interfaceXMLReader
- Throws:
SAXNotRecognizedException
SAXNotSupportedException
-
parse
- Specified by:
parse
in interfaceXMLReader
- Throws:
IOException
SAXException
-
parse
- Specified by:
parse
in interfaceXMLReader
- Throws:
IOException
SAXException
-
setContentHandler
this sets the ContentHandler that receives SAX events from the internal Blast XML parser which is the actual ContentHandler. It will not change the internal Blast XML parser.- Specified by:
setContentHandler
in interfaceXMLReader
-
setDTDHandler
- Specified by:
setDTDHandler
in interfaceXMLReader
-
setEntityResolver
This class has an EntityResolver that resolves the public ID specifying the NCBI DTDs to resource files within the BioJava libraries. This call will return that resolver. It you should set your own resolver, ensure you resolve that URN yourself or the parser will blow up on you!.- Specified by:
setEntityResolver
in interfaceXMLReader
-
setErrorHandler
- Specified by:
setErrorHandler
in interfaceXMLReader
-
setFeature
public void setFeature(String key, boolean value) throws SAXNotRecognizedException, SAXNotSupportedException by default, we set the parser to non-validating. change it if you wish/dare! The parser is also set to be namespace aware. DO NOT CHANGE THAT!!!- Specified by:
setFeature
in interfaceXMLReader
- Throws:
SAXNotRecognizedException
SAXNotSupportedException
-
setProperty
public void setProperty(String key, Object value) throws SAXNotRecognizedException, SAXNotSupportedException - Specified by:
setProperty
in interfaceXMLReader
- Throws:
SAXNotRecognizedException
SAXNotSupportedException
-