Home | Trees | Index | Help |
|
---|
Package Cheetah :: Module Compiler :: Class ModuleCompiler |
|
GenUtils
--+ |_SettingsCollector
--+ | | |SettingsManager
--+ | ModuleCompiler
Method Summary | |
---|---|
MUST BE CALLED BY SUBCLASSES | |
Provide one-way access to the methods and attributes of the ClassCompiler, and thereby the MethodCompilers as well. | |
__str__(self)
| |
addAttribute(self,
attribName,
expr)
| |
addComment(self,
comm)
| |
addImportedVarNames(self,
varNames)
| |
addImportStatement(self,
impStatement)
| |
Adds a line to the generated module docstring. | |
Adds a line of global module code. | |
Adds a header comment to the top of the generated module. | |
Adds module __specialConstant__ to the module globals. | |
classDefs(self)
| |
compile(self)
| |
getModuleCode(self)
| |
getModuleEncoding(self)
| |
importedVarNames(self)
| |
importStatements(self)
| |
moduleConstants(self)
| |
moduleDocstring(self)
| |
moduleFooter(self)
| |
moduleHeader(self)
| |
setBaseClass(self,
baseClassName)
| |
setCompilerSetting(self,
key,
valueExpr)
| |
setCompilerSettings(self,
keywords,
settingsStr)
| |
setModuleEncoding(self,
encoding)
| |
setShBang(self,
shBang)
| |
specialVars(self)
| |
timestamp(self,
theTime)
| |
wrapModuleDef(self)
| |
_addActiveClassCompiler(self,
classCompiler)
| |
_finishedClasses(self)
| |
_getActiveClassCompiler(self)
| |
A hook that allows for complex setting initialization sequences that involve references to 'self' or other settings. | |
_popActiveClassCompiler(self)
| |
_setupCompilerState(self)
| |
_spawnClassCompiler(self,
className,
klass)
| |
_swallowClassCompiler(self,
classCompiler)
| |
Inherited from SettingsManager | |
Returns a shallow copy of the settings dictionary | |
Returns a deep copy of the settings dictionary | |
Return a string with the settings in .ini file format. | |
True/False | |
Set a setting in self._settings. | |
Get a setting from self._settings, with or without a default value. | |
Return a reference to the settings dictionary | |
Update the settings with a selective merge or a complete overwrite. | |
Update the settings from a text file using the syntax accepted by Python's standard ConfigParser module (like Windows .ini files). | |
See the docstring for .updateSettingsFromConfigFile() | |
See the docstring for .updateSettingsFromConfigFile() | |
Update the settings from variables in a Python source file. | |
Update the settings from a code in a Python src string. | |
Write all the settings that can be represented as strings to an .ini style config file. | |
Write all the settings that can be represented as strings to an .ini style config string. | |
| |
Inherited from _SettingsCollector | |
Extract all the attributes of a SettingsContainer subclass. | |
Check if 'thing' is a Python module or a subclass of SettingsContainer. | |
A hook for any neccessary path manipulations. | |
| |
Return the settings from a config file that uses the syntax accepted by Python's standard ConfigParser module (like Windows .ini files). | |
Returns all settings from a SettingsContainer or Python module. | |
Returns all settings from a SettingsContainer or Python module. | |
Return new settings dict from variables in a Python source file. | |
Return a dictionary of the settings in a Python src string. | |
Inherited from GenUtils | |
Output something that gettext can recognize. | |
Decipher a placeholder cachetoken | |
| |
| |
Generate valid Python code for a Cheetah $var, using NameMapper (Unified Dotted Notation with the SearchList). | |
Generate Python code for a Cheetah $var without using NameMapper (Unified Dotted Notation with the SearchList). | |
|
Class Variable Summary | |
---|---|
classobj |
classCompilerClass = Cheetah.Compiler.AutoClassCompiler |
classobj |
parserClass = Cheetah.Parser._HighLevelParser |
Inherited from _SettingsCollector | |
lock |
_sysPathLock = <thread.lock object at 0xb7e5a560>
|
Method Details |
---|
__init__(self,
source=None,
file=None,
moduleName='DynamicallyCompiledCheetahTemplate',
mainClassName=None,
mainMethodName=None,
baseclassName=None,
extraImportStatements=None,
settings=None)
MUST BE CALLED BY SUBCLASSES |
__getattr__(self,
name)
|
addModuleDocString(self, line)Adds a line to the generated module docstring. |
addModuleGlobal(self, line)Adds a line of global module code. It is inserted after the import statements and Cheetah default module constants. |
addModuleHeader(self, line)Adds a header comment to the top of the generated module. |
addSpecialVar(self, basename, contents, includeUnderscores=True)Adds module __specialConstant__ to the module globals. |
_initializeSettings(self)A hook that allows for complex setting initialization sequences that involve references to 'self' or other settings. For example: self._settings['myCalcVal'] = self._settings['someVal'] * 15 This method should be called by the class' __init__() method when needed. The dummy implementation should be reimplemented by subclasses.
|
Home | Trees | Index | Help |
|
---|
Generated by Epydoc 2.1 on Sat Mar 4 13:36:24 2006 | http://epydoc.sf.net |