[Doc-SIG] Docutils transforms overhauled

David Goodger goodger@users.sourceforge.net
Wed, 23 Oct 2002 21:46:01 -0400


I just checked in a major change to the Docutils tranform handling
mechanism.  There's a new component, called "Transformer", which
centralizes and simplifies the transform handling that used to be
distributed between Reader and Writer objects.  I brought PEP 258 up
to date with this change and other recent changes.  Transformer
details can be found here:

    http://docutils.sf.net/spec/pep-0258.html#transformer
    http://docutils.sf.net/spec/transforms.html

The change simplifies the project model considerably::

                     +---------------------------+
                     |        Docutils:          |
                     | docutils.core.Publisher,  |
                     | docutils.core.publish_*() |
                     +---------------------------+
                      /            |            \
                     /             |             \
            1,3,5   /        6     |              \ 7
           +--------+       +-------------+       +--------+
           | READER | ----> | TRANSFORMER | ====> | WRITER |
           +--------+       +-------------+       +--------+
            /     \\                                  |
           /       \\                                 |
     2    /      4  \\                             8  |
    +-------+   +--------+                        +--------+
    | INPUT |   | PARSER |                        | OUTPUT |
    +-------+   +--------+                        +--------+

This change is internal and shouldn't have an impact on front ends or
client code.  If it breaks any code, please let me know.

The latest snapshot is always available from:

    http://docutils.sf.net/docutils-snapshot.tgz

-- 
David Goodger  <goodger@users.sourceforge.net>  Open-source projects:
  - Python Docutils: http://docutils.sourceforge.net/
    (includes reStructuredText: http://docutils.sf.net/rst.html)
  - The Go Tools Project: http://gotools.sourceforge.net/