Restartable Parsing
You must design the file parser so that parsing can be efficiently restarted
at discrete locations within the file. The goal is to give the display engine
the best performance without it having to store a completely converted copy of a
file.
To facilitate restartable parsing, the display engine incorporates a module,
which is called the
chunker, that essentially caches data from the parser. The chunker does not cache all
the data, only the data that the display engine has most recently requested.
However, it does cache state data for restartable locations in the file. This
means that as long as the parser maintains its own internal data in a way that
can be efficiently restarted, the display engine and the parser can work
cooperatively to locate and restart processing at the cached locations.
The file parser is responsible for determining the best locations for
restarting parsing. It does this by calling the
SOPutBreak function. The chunker assumes that each break is a restartable location in
the file. Before calling
SOPutBreak, however, the file parser must save up-to-date data about the location so
that it can quickly retrieve and begin processing the data at the location if
requested to do so.
The display engine uses the
VwStreamSeekFunc and
VwStreamTellFunc functions to direct the file parser to a restartable location.
- Software for developers
-
Delphi Components
.Net Components
Software for Android Developers
- More information resources
-
MegaDetailed.Net
Unix Manual Pages
Delphi Examples
- Databases for Amazon shops developers
-
Amazon Categories Database
Browse Nodes Database