This is the reference manual of trf 2.1p2, as distributed
at August 20, 2001. For instructions on how to compile and install it see
the installation manual.
After torturing the world with 2 extensions related to binary support
in tcl (blob and blobX) I could not resist and wrote another
This one is based on the idea to add hooks into the IO subsystem of
tcl allowing us to intercept any read/write call made by the user
and to act upon the data before it is given to him (read) or the
channel driver (write). This unfortunately requires us to patch the
core to get it going. See the technical explanation of the concept for more
information about this.
This requirement for tcl 7.6 is no such one for tcl 8.x. The
possibility to store binary data in normal variables allowed me to
rewrite the extension in such a way that its commands operate on
standard arguments and simply return their results. Of course, people
wanting to use the channel filter mode still need to patch the core.
Hopefully tcl 8.1 will contain the necessary hooks as part of the
core, obviating the need for patches. The probability is very low
however, due to the shift of the development from Sun to
Update: Tcl 8.2 made the patch official, i.e. it
was added to the core interpreter, obviating the need to patch it.
So, in conjunction with Tcl 8.2 this extension is a simple,
Please read the installation manual to gain insight into
the complete requirements of this extension.
At the C API level a set of commands is provided for
management, implementation and usage of ``transformer''-procedures.
These are called by the (patched) generic channel system to pre- or
postprocess data just before writing, resp. immediately after reading.
This allows transparent implementation of things like:
- Gathering statistics about the data flowing through a channel.
Converting in and out of printable representations of binary data.
- Decryption, encryption of information read or written.
- Data de(compression), error correcting coding.
to name only a few.
As proof of concept several such algorithms were implemented and are
provided as user-commands at the tcl-level.