========= generator ========= generator provides a class that execute a serie of tasks to generate the website, given a configuration. A task is a virtual class that provide a transformation for a given type of file. It is registered at runtime and its id correspond to the section it covers:: >>> from generator import BaseTask >>> class MyTask(BaseTask): ... def _getName(self): ... return 'glossary' ... def _run(self, configuration): ... print 'glossary processed' ... >>> from generator import registerTask >>> registerTask(MyTask) >>> class MyTask2(BaseTask): ... def _getName(self): ... return 'dummy' ... def _run(self, configuration): ... print 'dummy processed' ... >>> registerTask(MyTask2) The generator is programmed with a sequence of keys, that will call the task in order, with arguments:: >>> from generator import run >>> run(['glossary', 'dummy'], None) glossary processed dummy processed