Package Bio :: Package Entrez :: Module Parser :: Class DataHandler
[hide private]
[frames] | no frames]

Class DataHandler

source code

object --+

Instance Methods [hide private]
__init__(self, validate)
x.__init__(...) initializes x; see help(type(x)) for signature
source code
read(self, handle)
Set up the parser and let it parse the XML results
source code
parse(self, handle) source code
xmlDeclHandler(self, version, encoding, standalone) source code
startNamespaceDeclHandler(self, prefix, un) source code
startElementHandler(self, name, attrs) source code
endElementHandler(self, name) source code
characterDataHandler(self, content) source code
parse_xsd(self, root) source code
elementDecl(self, name, model)
This callback function is called for each element declaration: <!ELEMENT name (...)> encountered in a DTD. The purpose of this function is to determine whether this element should be regarded as a string, integer, list dictionary, structure, or error.
source code
open_dtd_file(self, filename) source code
open_xsd_file(self, filename) source code
save_dtd_file(self, filename, text) source code
save_xsd_file(self, filename, text) source code
externalEntityRefHandler(self, context, base, systemId, publicId)
The purpose of this function is to load the DTD locally, instead of downloading it from the URL specified in the XML. Using the local DTD results in much faster parsing. If the DTD is not found locally, we try to download it. If new DTDs become available from NCBI, putting them in Bio/Entrez/DTDs will allow the parser to see them.
source code

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Class Variables [hide private]
  local_dtd_dir = '/home/pc40583/.config/biopython/Bio/Entrez/DTDs'
  local_xsd_dir = '/home/pc40583/.config/biopython/Bio/Entrez/XSDs'
  global_dtd_dir = '/tmp/test-install/lib/python2.7/site-package...
  global_xsd_dir = '/tmp/test-install/lib/python2.7/site-package...
  exception = OSError(17, 'File exists')
Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, validate)

source code 
x.__init__(...) initializes x; see help(type(x)) for signature
Overrides: object.__init__
(inherited documentation)

Class Variable Details [hide private]