| www.delorie.com/gnu/docs/recode/recode_57.html | search |
![]() Buy GNU books! | |
recode reference manual| [ < ] | [ > ] | [ << ] | [ Up ] | [ >> ] | [Top] | [Contents] | [Index] | [ ? ] |
The trivial surface consists of using a fixed number of bits
(often eight) for each character, the bits together hold the integer
value of the index for the character in its charset table. There are
many kinds of surfaces, beyond the trivial one, all having the purpose
of increasing selected qualities for the storage or transmission.
For example, surfaces might increase the resistance to channel limits
(Base64), the transmission speed (gzip), the information
privacy (DES), the conformance to operating system conventions
(CR-LF), the blocking into records (VB), and surely other
things as well(17).
Many surfaces may be applied to a stream of characters from a charset,
the order of application of surfaces is important, and surfaces
should be removed in the reverse order of their application.
Even if surfaces may generally be applied to various charsets, some
surfaces were specifically designed for a particular charset, and would
not make much sense if applied to other charsets. In such cases, these
conceptual surfaces have been implemented as recode charsets,
instead of as surfaces. This choice yields to cleaner syntax
and usage. See section 5. The universal charset.
Surfaces are implemented within recode as special charsets
which may only transform to or from the data or tree
special charsets. Clever users may use this knowledge for writing
surface names in requests exactly as if they were pure charsets, when
the only need is to change surfaces without any kind of recoding between
real charsets. In such contexts, either data or tree may
also be used as if it were some kind of generic, anonymous charset: the
request `data..surface' merely adds the given surface,
while the request `surface..data' removes it.
The recode library distinguishes between mere data surfaces, and
structural surfaces, also called tree surfaces for short. Structural
surfaces might allow, in the long run, transformations between a few
specialised representations of structural information like MIME parts,
Perl or Python initialisers, LISP S-expressions, XML, Emacs outlines, etc.
We are still experimenting with surfaces in recode. The concept opens
the doors to many avenues; it is not clear yet which ones are worth pursuing,
and which should be abandoned. In particular, implementation of structural
surfaces is barely starting, there is not even a commitment that tree
surfaces will stay in recode, if they do prove to be more cumbersome
than useful. This chapter presents all surfaces currently available.
13.1 Permuting groups of bytes 13.2 Representation for end of lines 13.3 MIME contents encodings 13.4 Interpreted character dumps 13.5 Artificial data for testing
| [ < ] | [ > ] | [ << ] | [ Up ] | [ >> ] | [Top] | [Contents] | [Index] | [ ? ] |
| webmaster donations bookstore | delorie software privacy |
| Copyright © 2003 by The Free Software Foundation | Updated Jun 2003 |