The Tigris site will receive a major upgrade the evening of Monday, December 1, beginning at 8:30 pm PST. Downtime is projected to be about ten hours.
Further details in the announcement
Class Itpl
Class representing a string with interpolation abilities.
Upon creation, an instance works out what parts of the format string
are literal and what parts need to be evaluated. The evaluation and
substitution happens in the namespace of the caller when str(instance) is
called.
| Method Summary |
| |
__init__(self,
format)
The single argument to this constructor is a format string. |
| |
__repr__(self)
|
| |
__str__(self)
Evaluate and substitute the appropriate parts of the string. |
__init__(self,
format)
(Constructor)
The single argument to this constructor is a format string.
The format string is parsed according to the following rules:
1. A dollar sign and a name, possibly followed by any of:
- an open-paren, and anything up to the matching paren
- an open-bracket, and anything up to the matching bracket
- a period and a name
any number of times, is evaluated as a Python expression.
2. A dollar sign immediately followed by an open-brace, and
anything up to the matching close-brace, is evaluated as
a Python expression.
3. Outside of the expressions described in the above two rules,
two dollar signs in a row give you one literal dollar sign.
-
|
__str__(self)
(Informal representation operator)
Evaluate and substitute the appropriate parts of the string.
-
|