4 #include <emscripten.h>
14 FS.mount(NODEFS, {root:
'.'},
"/work");
24 termgenerator.
index_text(
"This is a test document.");
25 db.replace_document(
"Q1", doc);
27 cout <<
"Created database with " << db.get_doccount()
28 <<
" documents" << endl;
Class representing a document.
Parses a piece of text and generate terms.
void index_text(const Xapian::Utf8Iterator &itor, Xapian::termcount wdf_inc=1, std::string_view prefix={})
Index some text.
void set_document(const Xapian::Document &doc)
Set the current document.
This class provides read/write access to a database.
const int DB_CREATE_OR_OPEN
Create database if it doesn't already exist.
Public interfaces for the Xapian library.