API to be provided by a "template engine": compile_string(text), compile_stream(input_stream) - return a WSGI application object for the template described by the text or file-like object
write_compiled(app, output_stream) - save the compiled form of the template to output_stream read_compiled(input_stream) - read a template from input_stream and return a WSGI application object I believe that this is all that can reasonably be standardized by the Web-SIG at this time for a template API, while still treating its constituents fairly. (i.e., not disadvantaging more advanced frameworks by being a least-common-denominator approach). The only other thing that might be suitable for standardization would be any common extra 'environ' keys that might be considered desirable, like a "published object" key to hold the "vars" (for "controller"-style frameworks that postprocess a function return value) or to hold the "self" object (for Zope-style object publishing frameworks that apply a template as a view of the object addressed in the URL). _______________________________________________ Web-SIG mailing list Web-SIG@python.org Web SIG: http://www.python.org/sigs/web-sig Unsubscribe: http://mail.python.org/mailman/options/web-sig/archive%40mail-archive.com