Project Lucy has retired. For details please refer to its Attic page.
Lucy::Plan::Architecture – C API Documentation
Apache Lucy™

Lucy::Plan::Architecture

parcel Lucy
class variable LUCY_ARCHITECTURE
struct symbol lucy_Architecture
class nickname lucy_Arch
header file Lucy/Plan/Architecture.h

Name

Lucy::Plan::Architecture – Configure major components of an index.

Description

By default, a Lucy index consists of several main parts: lexicon, postings, stored documents, deletions, and highlight data. The readers and writers for that data are spawned by Architecture. Each component operates at the segment level; Architecture’s factory methods are used to build up SegWriter and SegReader.

Functions

new
lucy_Architecture* // incremented
lucy_Arch_new(void);

Constructor. Takes no arguments.

init
lucy_Architecture*
lucy_Arch_init(
    lucy_Architecture *self
);

Initialize an Architecture.

Methods

Register_Doc_Writer
void
lucy_Arch_Register_Doc_Writer(
    lucy_Architecture *self,
    lucy_SegWriter *writer
);

Spawn a DataWriter and Register() it with the supplied SegWriter, adding it to the SegWriter’s writer stack.

writer

A SegWriter.

Register_Doc_Reader
void
lucy_Arch_Register_Doc_Reader(
    lucy_Architecture *self,
    lucy_SegReader *reader
);

Spawn a DocReader and register it with the supplied SegReader.

reader

A SegReader.

Equals
bool
lucy_Arch_Equals(
    lucy_Architecture *self,
    cfish_Obj *other
);

Returns true for any Architecture object. Subclasses should override this weak check.

Inheritance

Lucy::Plan::Architecture is a Clownfish::Obj.