Package Bio :: Package config :: Module DBRegistry :: Class CGIDB
[hide private]
[frames] | no frames]

Class CGIDB

source code

Registry.RegisterableObject --+    
                              |    
                       DBObject --+
                                  |
                  TextLikeMixin --+
                                  |
                                 CGIDB

This class implements DBObject for accessing CGI databases.

Instance Methods [hide private]
 
__init__(self, name, cgi, url=None, key=None, params=None, abbrev=None, doc=None, delay=None, timeout=None, getmethod=1, failure_cases=None)
CGIDB(name, cgi[, url][, key][, params][, abbrev][, doc] [, delay][, timeout][, getmethod][, failure_cases])
source code
 
_normalize_params(self, key) source code
data
_get(self, key) source code
 
_cgiopen(self, key) source code
pickleable_obj
_make_pickleable(self, handle) source code
data
_unmake_pickleable(self, obj) source code

Inherited from DBObject: __getitem__, get, get_as, set

Inherited from DBObject (private): _convert_to, _set

Inherited from TextLikeMixin (private): _check_for_errors

Method Details [hide private]

__init__(self, name, cgi, url=None, key=None, params=None, abbrev=None, doc=None, delay=None, timeout=None, getmethod=1, failure_cases=None)
(Constructor)

source code 

CGIDB(name, cgi[, url][, key][, params][, abbrev][, doc] [, delay][, timeout][, getmethod][, failure_cases])

name is the name of the object, abbrev is an abbreviation for the name, and doc is some documentation describing the object.

cgi is the URL for the cgi script. url points to the human-readable URL of the form.

params is a list of (key, value) tuples indicating the parameters that should be passed to the CGI script. key is the name of the parameter for the CGI script whose value is the ID of the object to retrieve.

getmethod is a boolean describing whether a GET or POST should be used. By default, GET is used.

failure_cases is a list of (Martel Expression, error message) describing patterns of errors in the text returned by the script.

Overrides: Registry.RegisterableObject.__init__

_get(self, key)

source code 
Returns: data
Overrides: DBObject._get
(inherited documentation)

_make_pickleable(self, handle)

source code 
Returns: pickleable_obj
Overrides: DBObject._make_pickleable
(inherited documentation)

_unmake_pickleable(self, obj)

source code 
Returns: data
Overrides: DBObject._unmake_pickleable
(inherited documentation)