Home | History | Annotate | Download | only in Lib

Lines Matching defs:Template

14 The module lets you construct a pipeline template by sticking one or
17 data. You can then use the template to do conversions from many
19 file names used are different each time the template is used.
29 To create a template:
30 t = Template()
32 To add a conversion step to a template:
44 To convert a file to another file using a template:
55 To create a new template object initialized to a given one:
65 __all__ = ["Template"]
80 class Template:
81 """Class representing a pipeline template."""
84 """Template() returns a fresh pipeline template."""
90 return '<Template instance, steps=%r>' % (self.steps,)
93 """t.reset() restores a pipeline template to its initial state."""
97 """t.clone() returns a new pipeline template with identical
99 t = Template()
112 'Template.append: cmd must be a string'
115 'Template.append: bad kind %r' % (kind,)
118 'Template.append: SOURCE can only be prepended'
121 'Template.append: already ends with SINK'
124 'Template.append: missing $IN in cmd'
127 'Template.append: missing $OUT in cmd'
134 'Template.prepend: cmd must be a string'
137 'Template.prepend: bad kind %r' % (kind,)
140 'Template.prepend: SINK can only be appended'
143 'Template.prepend: already begins with SOURCE'
146 'Template.prepend: missing $IN in cmd'
149 'Template.prepend: missing $OUT in cmd'
160 'Template.open: rw must be \'r\' or \'w\', not %r' % (rw,)
169 'Template.open_r: pipeline ends width SINK'
178 'Template.open_w: pipeline begins with SOURCE'