The service class Text contains those methods needed to manage ordered sequences of
variable length text records, numbered from 1 to n. These are referred to as "text streams".
The typical retrieval pattern for text streams is that they are first moved to a certain
record in the sequence and then a series of records is accessed from there. The algorithm
used is optimal for moving forward through a sequence records once a starting location has
been established. As such, the general approach differs from those for "normal" sequences in
that the notion of a "current record" or "cursor" is used. The sequence is positioned on a
record and that current record can then be manipulated. In addition to optimizing the
traversal through the records, the approach also optimizes the storage and changing of
records. The individual records are stored in fixed sized blocks in long memory. When a
record in inserted into the stream or when the size of a record is changed only the block
containing the record needs to be repositioned, not the entire stream. Finally, each text
record in the stream consists of two parts: a fixed length component called the "record
associated information" followed by the remaining text part, simply called the "record".
There is no actual requirement within this class that the records being managed be text
records. This class simply maintains them as opaque blocks of bytes with individually
specified lengths and associated information. The actual implementation code simply refers
to the records being managed as variable length records.