string :: Template :: Class Template
[hide private]
[frames] | no frames]

Class Template

source code

object --+
         |
        Template

A string class for supporting $-substitutions.

Nested Classes [hide private]
  __metaclass__
Instance Methods [hide private]
 
__init__(self, template)
x.__init__(...) initializes x; see x.__class__.__doc__ for signature
source code
 
_invalid(self, mo) source code
 
safe_substitute(self, *args, **kws) source code
 
substitute(self, *args, **kws) source code

Inherited from object: __delattr__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __str__

Class Variables [hide private]
  delimiter = '$'
  idpattern = '[_a-z][_a-z0-9]*'
  pattern = re.compile(r'(?ix)\$(?:(?P<escaped>\$)|(?P<named>[_a...
Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, template)
(Constructor)

source code 
x.__init__(...) initializes x; see x.__class__.__doc__ for signature
Overrides: object.__init__
(inherited documentation)

Class Variable Details [hide private]

pattern

Value:
re.compile(r'(?ix)\$(?:(?P<escaped>\$)|(?P<named>[_a-z][_a-z0-9]*)|\{(\
?P<braced>[_a-z][_a-z0-9]*)\}|(?P<invalid>))')