Method Summary |
|
_initializeSettings(self)
|
|
_makeCheetahVarREs (self)
Setup the regexs for Cheetah $var parsing. |
|
_makeCommentREs (self)
Construct the regex bits that are used in comment parsing. |
|
_makeDirectiveREs (self)
Construct the regexs that are used in directive parsing. |
|
_makePspREs (self)
Setup the regexs for PSP parsing. |
|
configureParser (self)
Is called by the Compiler instance after the parser has had a
settingsManager assigned with self.setSettingsManager() |
|
getAssignmentOperator(self)
|
|
getCacheToken(self)
|
|
getCallArgString (self,
enclosures,
useNameMapper)
Get a method/function call argument string. |
|
getCheetahVar (self,
plain,
skipStartToken)
This is called when parsing inside expressions. |
|
getCheetahVarBody(self,
plain)
|
|
getCheetahVarNameChunks (self)
[ (namemapperPart,autoCall,restOfName),
] |
|
getCheetahVarStartToken (self)
just the start token, not the enclosure or cache token |
|
getCommentStartToken(self)
|
|
getDefArgList (self,
exitPos,
useNameMapper)
Get an argument list. |
|
getDirectiveEndToken(self)
|
|
getDirectiveStartToken(self)
|
|
getDottedName(self)
|
|
getEOLSlurpToken(self)
|
|
getExpression (self,
enclosed,
enclosures,
pyTokensToBreakAt,
useNameMapper)
Returns the output of self.getExpressionParts() as a concatenated
string rather than as a list. |
|
getExpressionParts (self,
enclosed,
enclosures,
pyTokensToBreakAt,
useNameMapper)
Get a Cheetah expression that includes $CheetahVars and break at
directive end tokens, the end of an enclosure, or at a specified
pyToken. |
|
getIdentifier(self)
|
|
getMultiLineCommentEndToken(self)
|
|
getMultiLineCommentStartToken(self)
|
|
getOperator(self)
|
|
getPlaceholder(self,
allowCacheTokens,
plain,
returnEverything)
|
|
getPSPEndToken(self)
|
|
getPSPStartToken(self)
|
|
getPyToken(self)
|
|
getSilentPlaceholderToken(self)
|
|
getTargetVarsList(self)
|
|
isLineClearToStartToken(self,
pos)
|
|
matchAssignmentOperator(self)
|
|
matchCheetahVarStart (self)
includes the enclosure and cache token |
|
matchCheetahVarStartToken (self)
includes the enclosure and cache token |
|
matchColonForSingleLineShortFormDirective(self)
|
|
matchCommentStartToken(self)
|
|
matchDirective (self)
Returns False or the name of the directive matched. |
|
matchDirectiveEndToken(self)
|
|
matchDirectiveName(self,
directiveNameChars)
|
|
matchDirectiveStartToken(self)
|
|
matchEOLSlurpToken(self)
|
|
matchExpressionPlaceholderStart (self)
includes the enclosure and cache token |
|
matchIdentifier(self)
|
|
matchMultiLineCommentEndToken(self)
|
|
matchMultiLineCommentStartToken(self)
|
|
matchOperator(self)
|
|
matchPSPEndToken(self)
|
|
matchPSPStartToken(self)
|
|
matchPyToken(self)
|
|
matchTopLevelToken (self)
self.matchCommentStartToken
self.matchMultiLineCommentStartToken
self.matchVariablePlaceholderStart
self.matchExpressionPlaceholderStart
self.matchDirective
self.matchPSPStartToken
self.matchEOLSlurpToken |
|
matchVariablePlaceholderStart (self)
includes the enclosure and cache token |
|
setSetting(self,
key,
val)
|
|
setSettingsManager(self,
settingsManager)
|
|
setting(self,
key,
default)
|
|
settings(self)
|
|
transformToken (self,
token,
beforeTokenPos)
Takes a token from the expression being parsed and performs and
special transformations required by Cheetah. |
|
updateSettings(self,
settings)
|
Inherited from SourceReader |
|
__init__ (self,
src,
filename,
breakPoint,
encoding)
|
|
__getitem__ (self,
i)
|
|
__getslice__ (self,
i,
j)
|
|
__len__ (self)
|
|
advance (self,
offset)
|
|
atEnd (self)
|
|
atStart (self)
|
|
breakPoint (self)
|
|
checkPos (self,
pos)
|
|
filename (self)
|
|
find (self,
it,
pos)
|
|
findBOL (self,
pos)
|
|
findEOL (self,
pos,
gobble)
|
|
getc (self)
|
|
getLine (self,
pos)
|
|
getNonWhiteSpace (self,
WSchars)
|
|
getRowCol (self,
pos)
|
|
getRowColLine (self,
pos)
|
|
getWhiteSpace (self,
max,
WSchars)
|
|
gotoBookmark (self,
name)
|
|
hasBookmark (self,
name)
|
|
isLineClearToPos (self,
pos)
|
|
lineNum (self,
pos)
|
|
matches (self,
strOrRE)
|
|
matchNonWhiteSpace (self,
WSchars)
|
|
matchWhiteSpace (self,
WSchars)
|
|
peek (self,
offset)
|
|
pos (self)
|
|
read (self,
offset)
|
|
readTo (self,
to,
start)
|
|
readToEOL (self,
start,
gobble)
|
|
rev (self,
offset)
|
|
rfind (self,
it,
pos)
|
|
setBookmark (self,
name)
|
|
setBreakPoint (self,
pos)
|
|
setPos (self,
pos)
|
|
splitlines (self)
|
|
src (self)
|
|
startswith (self,
it,
pos)
|
|
ungetc (self,
c)
|
|
validPos (self,
pos)
|