Patent Document ID: 5412807
Application ID: 07932758
Patent Status: 1

Claim One:
1. A method of searching a text file for the occurrence of user-selected portions of text that satisfy user-specified conditions, the method comprising the steps of: (a) providing a full-text index containing location information about all words in the text file; (b) constructing an n-ary Boolean search tree corresponding to the user-selected text portions and a logical interrelation of the user-selected text portions required to satisfy the user-specified conditions where n is greater than two, said search tree containing a plurality of terminal nodes defining a plurality of word terms corresponding to the user-selected text portions, a plurality of non-terminal nodes each containing a logical operator term corresponding to said logical interrelation of said word terms, and a root node corresponding to portions of the text file where the user-selected text portions satisfy the user-specified conditions; (c) constructing a plurality of index lists, corresponding in number to said plurality of word terms, from said full-text index, each of said index lists associated with a corresponding word term and containing a sequential listing of all occurrences of said corresponding word term in the text file starting at a first end of the text file and the location in the text file of each occurrence of said corresponding word term; (d) providing an index pointer for each of said plurality of index lists, each of said index pointers selecting a current occurrence in each of said plurality of index lists, said index pointers initially selecting a first location in each of said plurality of index lists; (e) providing a Boolean pointer pointing to a selected non-terminal node on said search tree; (f) applying said logical operator term at said selected non-terminal node to said current occurrence in each of said plurality of index lists for word terms at terminal nodes adjacent to said selected non-terminal node; (g) generating a hit indicator when said occurrence in each of said plurality of index lists for word terms at terminal nodes adjacent to said selected non-terminal node satisfies said logical operator term at said selected non-terminal node; (h) temporarily storing a list of locations within the text file for which the word terms at adjacent terminal nodes satisfy said logical operator term at each of said non-terminal nodes; and (i) advancing said index pointer for one of said index lists for which said current occurrence is at the location in the text file nearest said first end if said hit indicator is not generated or if said logical operator term at said selected non-terminal node is an OR operator, and advancing said index pointer for one of said index lists for which the next sequential occurrence in the text file is at the location in the text file nearest said first end if said hit indicator is generated.