KinoSearch::InvIndex - An inverted index.
my $invindex = MySchema->clobber('/path/to/invindex');
# ... which is equivalent to:
my $folder = KinoSearch::Store::FSFolder->new(
path => '/path/to/invindex',
);
my $invindex = KinoSearch::InvIndex->clobber(
schema => MySchema->new,
folder => $folder,
);
"InvIndex" is short for "inverted index", the name for the data structure which KinoSearch is based around. Generically, an inverted index, as opposed to any other kind of index, contains mappings from keywords to documents, allowing you to look up a term and find out where it occurs within a collection.
A KinoSearch::InvIndex object has two main parts: a Schema and a Folder. The Schema describes how the index data is structured, and the Folder provides the I/O capabilities for actually getting at the data and doing something with it.
InvIndex provides three constructors: clobber(), open(), and read(), which are
usually invoked internally via factory methods from Schema. However, when
called directly, InvIndex's constructors allow you more flexibility in
supplying the folder argument, so you can do things like supply a
RAMFolder.
my $invindex = KinoSearch::InvIndex->clobber(
schema => $schema,
folder => $folder,
);
# or...
my $invindex = KinoSearch::InvIndex->open(
schema => $schema,
folder => $folder,
);
# or...
my $invindex = KinoSearch::InvIndex->read(
schema => $schema,
folder => $folder,
);
Accessor.
Accessor.
KinoSearch::InvIndex isa KinoSearch::Obj.
Copyright 2005-2008 Marvin Humphrey
See KinoSearch version 0.20.