Documentation on how to use the SimpleTAL API.

SimpleTAL API

ExpenseClam
Easy-to-use business expense tracker for Android.

ExpenseClam for Android

SimpleTAL consists of four different modules: simpleTAL, simpleTALES, simpleTALUtils and simpleElementTree.  The API for each of these modules is documented separately:

  • simpleTAL - contains functions to compile HTML and XML templates into objects ready for use.
  • simpleTALES - contains the Context class which provides the environment in which templates are expanded.
  • simpleTALUtils - optional utility functions for dealing with SimpleTAL templates.
  • simpleElementTree - integration with ElementTree allowing XML documents to be parsed and placed directly into the Context instance.

Logging in SimpleTAL

To control the output of logging messages from SimpleTAL it is necessary to retrieve the logger objects for each module, which can be done using:

simpleTALLogger = logging.getLogger ("simpleTAL")
simpleTALESLogger = logging.getLogger ("simpleTALES")

The configuration of these loggers can then be adjusted as described in the logging library documentation.  For example to stop warnings being logged:

simpleTALLogger.setLevel (logging.ERROR)
simpleTALESLogger.setLevel (logging.ERROR)

Back to SimpleTAL

%nbsp;

Last Modified: Sat, 15 Aug 2009 12:21:07 BST

Made with PubTal 3.5

Copyright 2013 Colin Stewart

Email: colin at owlfish.com