class documentation

A search for finding entries whose titles start with a certain prefix.

This search is case sensitive!

Method __init__ The default constructor.
Method search Perform a search.
Method search_in_range Perform a range-limited search.
Instance Variable _titlepointerlist Undocumented

Inherited from BaseSearch:

Method close Perform any necessary cleanup.
Instance Variable zim the ZIM archive this search is for
def __init__(self, *args, search_nonarticles=False, **kwargs):

The default constructor.

All arguments that are not specific for this method will be passed to the superclass.

Parameters
*argsUndocumented
search_nonarticles:boolif nonzero, search all entries and not only the articles. In this case, the search terms must begin with the namespace.
**kwargsUndocumented
def search(self, term):

Perform a search.

Parameters
term:strterm to search for
Returns
SearchResultSetan object containing the search results
def search_in_range(self, term, start=None, n=20):

Perform a range-limited search.

This function is primarily a helper function used by SearchResultSet to iteratively fetch new results, but it can still be used independently. Just beware of the different return type.

Parameters
term:strterm to search for
start:intstart (1-based index) of the results to find
n:intnumber of results to fetch
Returns
list of SearchResultan object containing the search results
_titlepointerlist =

Undocumented