Base class to take some kind of input data (probably a file), iterate
through it's contents and process it accordingly, possibly calculating
and formatting different values and then submitting them for output
(probably a database).
The core structure is in the run method, leaving most of the details
to independent processor and iterator preparer objects for each table.
Standard ones are included in this module, but additional processors can
be created and added for customized curation / processing.
The structure of the run method will likely have dependence and map to
the schema structure of the output (database), and thus should be
overridden and customized by sub-classes
|
|
|
loadOptions(self,
options)
Load any relevant options from the command-line parser. |
|
|
|
addProcessor(self,
processor) |
|
|
|
clearProcessors(self,
tableName) |
|
|
|
setIteratorPreparer(self,
preparer) |
|
|
|
prepareIterator(self,
tableName,
parentObj)
Given a tableName, look for an iterator preparer object previously
set in the preparerDict. |
|
|
|
processObject(self,
tableName,
parentObj,
currObj)
Given a tableName, look for a list of processor objects previously
added in the processorsDict. |
|
|
|
run(self)
Primary method that traverses through the database schema,
populating it with the input data as it goes. |
|
|