<!DOCTYPE File PUBLIC "-//Liam Quin//DTD C API Documentation v1.1//EN" "doc.dtd"><File>
<Entry dir="liblqtext">
<Function File="../../src/liblqtext/wordinfo.c">
<Name>LQT_PutWordInfoIntoIndex</Name>
<Class>Database/Update, Database/Words
<Purpose>
<P>Each WordInfo structure contains a pointer to a single data block,
which is used to store the widindex header.
This speeds up indexing, since the header is needed at both the
start of writing out WordPlaces and at the end.
LQT_PutWordInfoIntoIndex arranges that index block be written
out to the widindex index file, using LQT_WriteWordInfoIndexBlock.</P>
<P>A WID must have been allocated for this word with LQT_WriteWordAndWID
for this word already, on this or some other program run.</P>
<P>This routine is generally called after LQT_Writepblock.</P>
<Returns>
zero
<Errors>
Warns if the WordInfo has a datablock but no offset.
If ASCIITRACE was defined when the library was compiled, and if
the LQTRACE_READAFTERWRITE trace flag is set, LQT_PutWordInfoIntoIndex
checks that theWordinfo->WID corresponds to theWordInfo->Word,
using LQT_WordToWID, and produces a fatal (E_BUG) error if not.
</Function>
<Decl>
API int
LQT_PutWordInfoIntoIndex(db, theWordInfo, Offset)
    t_LQTEXT_Database *db;
    t_WordInfo *theWordInfo;
    unsigned long Offset;
</Decl>
</Entry>
