| database.h | | database.h | |
| | | | |
| skipping to change at line 134 | | skipping to change at line 134 | |
| * Calling reopen() on a database which has been closed (with @a | | * Calling reopen() on a database which has been closed (with @a | |
| * close()) will always raise a Xapian::DatabaseError. | | * close()) will always raise a Xapian::DatabaseError. | |
| */ | | */ | |
| void reopen(); | | void reopen(); | |
| | | | |
| /** Close the database. | | /** Close the database. | |
| * | | * | |
| * This closes the database and releases all file handles held by t
he | | * This closes the database and releases all file handles held by t
he | |
| * database. | | * database. | |
| * | | * | |
|
| * This is a permanent close of the database: calling reopen() afte | | * This cannot be undone - in particular, calling reopen() after | |
| r | | * closing a database will not reopen it, but will instead throw a | |
| * closing a database will not reopen it, and will raise an excepti | | * Xapian::DatabaseError exception. | |
| on. | | | |
| * | | | |
| * Calling close() on a database which is already closed has no eff | | | |
| ect | | | |
| * (and doesn't raise an exception). | | | |
| * | | * | |
|
| * After this call, calls made to methods of the database (other th | | * Calling close() again on a database which has already been close | |
| an | | d | |
| * close() or the destructor), or to objects associated with the | | * has no effect (and doesn't raise an exception). | |
| * database will behave in one of the following ways (but which | | | |
| * behaviour happens may vary between releases, and between databas | | | |
| e | | | |
| * backends): | | | |
| * | | * | |
|
| * - raise a Xapian::DatabaseError indicating that the database is | | * After close() has been called, calls to other methods of the | |
| * closed. | | * database, and to methods of other objects associated with the | |
| | | * database, will either: | |
| * | | * | |
| * - behave exactly as they would have done if the database had no
t | | * - behave exactly as they would have done if the database had no
t | |
|
| * been closed (by using cached data). | | * been closed (this can only happen if all the required data is | |
| | | * cached) | |
| * | | * | |
|
| * To summarise - you should not rely on the exception being raised | | * - raise a Xapian::DatabaseError exception indicating that the | |
| , | | * database is closed. | |
| * or the normal result being available, but if you do get a result | | * | |
| , | | * The reason for this behaviour is that otherwise we'd have to che | |
| * it will be correct. | | ck | |
| | | * that the database is still open on every method call on every | |
| | | * object associated with a Database, when in many cases they are | |
| | | * working on data which has already been loaded and so they are ab | |
| | | le | |
| | | * to just behave correctly. | |
| */ | | */ | |
| virtual void close(); | | virtual void close(); | |
| | | | |
| /// Return a string describing this object. | | /// Return a string describing this object. | |
| virtual std::string get_description() const; | | virtual std::string get_description() const; | |
| | | | |
| /** An iterator pointing to the start of the postlist | | /** An iterator pointing to the start of the postlist | |
| * for a given term. | | * for a given term. | |
| * | | * | |
| * If the term name is the empty string, the iterator returned | | * If the term name is the empty string, the iterator returned | |
| * will list all the documents in the database. Such an iterator | | * will list all the documents in the database. Such an iterator | |
| * will always return a WDF value of 1, since there is no obvious | | * will always return a WDF value of 1, since there is no obvious | |
| * meaning for this quantity in this case. | | * meaning for this quantity in this case. | |
| */ | | */ | |
| PostingIterator postlist_begin(const std::string &tname) const; | | PostingIterator postlist_begin(const std::string &tname) const; | |
| | | | |
| /** Corresponding end iterator to postlist_begin(). | | /** Corresponding end iterator to postlist_begin(). | |
| */ | | */ | |
| PostingIterator postlist_end(const std::string &) const { | | PostingIterator postlist_end(const std::string &) const { | |
|
| return PostingIterator(NULL); | | return PostingIterator(); | |
| } | | } | |
| | | | |
| /** An iterator pointing to the start of the termlist | | /** An iterator pointing to the start of the termlist | |
| * for a given document. | | * for a given document. | |
| */ | | */ | |
| TermIterator termlist_begin(Xapian::docid did) const; | | TermIterator termlist_begin(Xapian::docid did) const; | |
| | | | |
| /** Corresponding end iterator to termlist_begin(). | | /** Corresponding end iterator to termlist_begin(). | |
| */ | | */ | |
| TermIterator termlist_end(Xapian::docid) const { | | TermIterator termlist_end(Xapian::docid) const { | |
|
| return TermIterator(NULL); | | return TermIterator(); | |
| } | | } | |
| | | | |
| /** Does this database have any positional information? */ | | /** Does this database have any positional information? */ | |
| bool has_positions() const; | | bool has_positions() const; | |
| | | | |
| /** An iterator pointing to the start of the position list | | /** An iterator pointing to the start of the position list | |
| * for a given term in a given document. | | * for a given term in a given document. | |
| */ | | */ | |
| PositionIterator positionlist_begin(Xapian::docid did, const std::st
ring &tname) const; | | PositionIterator positionlist_begin(Xapian::docid did, const std::st
ring &tname) const; | |
| | | | |
| /** Corresponding end iterator to positionlist_begin(). | | /** Corresponding end iterator to positionlist_begin(). | |
| */ | | */ | |
| PositionIterator positionlist_end(Xapian::docid, const std::string &
) const { | | PositionIterator positionlist_end(Xapian::docid, const std::string &
) const { | |
|
| return PositionIterator(NULL); | | return PositionIterator(); | |
| } | | } | |
| | | | |
| /** An iterator which runs across all terms in the database. | | /** An iterator which runs across all terms in the database. | |
| */ | | */ | |
| TermIterator allterms_begin() const; | | TermIterator allterms_begin() const; | |
| | | | |
| /** Corresponding end iterator to allterms_begin(). | | /** Corresponding end iterator to allterms_begin(). | |
| */ | | */ | |
| TermIterator allterms_end() const { | | TermIterator allterms_end() const { | |
|
| return TermIterator(NULL); | | return TermIterator(); | |
| } | | } | |
| | | | |
| /** An iterator which runs across all terms with a given prefix. | | /** An iterator which runs across all terms with a given prefix. | |
| * | | * | |
| * This is functionally similar to getting an iterator with | | * This is functionally similar to getting an iterator with | |
| * allterms_begin() and then calling skip_to(prefix) on that iterat
or | | * allterms_begin() and then calling skip_to(prefix) on that iterat
or | |
| * to move to the start of the prefix, but is more convenient (beca
use | | * to move to the start of the prefix, but is more convenient (beca
use | |
| * it detects the end of the prefixed terms), and may be more | | * it detects the end of the prefixed terms), and may be more | |
| * efficient than simply calling skip_to() after opening the iterat
or, | | * efficient than simply calling skip_to() after opening the iterat
or, | |
| * particularly for remote databases. | | * particularly for remote databases. | |
| * | | * | |
| * @param prefix The prefix to restrict the returned terms to. | | * @param prefix The prefix to restrict the returned terms to. | |
| */ | | */ | |
| TermIterator allterms_begin(const std::string & prefix) const; | | TermIterator allterms_begin(const std::string & prefix) const; | |
| | | | |
| /** Corresponding end iterator to allterms_begin(prefix). | | /** Corresponding end iterator to allterms_begin(prefix). | |
| */ | | */ | |
| TermIterator allterms_end(const std::string &) const { | | TermIterator allterms_end(const std::string &) const { | |
|
| return TermIterator(NULL); | | return TermIterator(); | |
| } | | } | |
| | | | |
| /// Get the number of documents in the database. | | /// Get the number of documents in the database. | |
| Xapian::doccount get_doccount() const; | | Xapian::doccount get_doccount() const; | |
| | | | |
| /// Get the highest document id which has been used in the database. | | /// Get the highest document id which has been used in the database. | |
| Xapian::docid get_lastdocid() const; | | Xapian::docid get_lastdocid() const; | |
| | | | |
| /// Get the average length of the documents in the database. | | /// Get the average length of the documents in the database. | |
| Xapian::doclength get_avlength() const; | | Xapian::doclength get_avlength() const; | |
| | | | |
| skipping to change at line 366 | | skipping to change at line 368 | |
| * | | * | |
| * This returns all the words which are considered as targets for t
he | | * This returns all the words which are considered as targets for t
he | |
| * spelling correction algorithm. The frequency of each word is | | * spelling correction algorithm. The frequency of each word is | |
| * available as the term frequency of each entry in the returned | | * available as the term frequency of each entry in the returned | |
| * iterator. | | * iterator. | |
| */ | | */ | |
| Xapian::TermIterator spellings_begin() const; | | Xapian::TermIterator spellings_begin() const; | |
| | | | |
| /// Corresponding end iterator to spellings_begin(). | | /// Corresponding end iterator to spellings_begin(). | |
| Xapian::TermIterator spellings_end() const { | | Xapian::TermIterator spellings_end() const { | |
|
| return Xapian::TermIterator(NULL); | | return Xapian::TermIterator(); | |
| } | | } | |
| | | | |
| /** An iterator which returns all the synonyms for a given term. | | /** An iterator which returns all the synonyms for a given term. | |
| * | | * | |
| * @param term The term to return synonyms for. | | * @param term The term to return synonyms for. | |
| */ | | */ | |
| Xapian::TermIterator synonyms_begin(const std::string &term) const; | | Xapian::TermIterator synonyms_begin(const std::string &term) const; | |
| | | | |
| /// Corresponding end iterator to synonyms_begin(term). | | /// Corresponding end iterator to synonyms_begin(term). | |
| Xapian::TermIterator synonyms_end(const std::string &) const { | | Xapian::TermIterator synonyms_end(const std::string &) const { | |
|
| return Xapian::TermIterator(NULL); | | return Xapian::TermIterator(); | |
| } | | } | |
| | | | |
| /** An iterator which returns all terms which have synonyms. | | /** An iterator which returns all terms which have synonyms. | |
| * | | * | |
| * @param prefix If non-empty, only terms with this prefix are | | * @param prefix If non-empty, only terms with this prefix are | |
| * returned. | | * returned. | |
| */ | | */ | |
| Xapian::TermIterator synonym_keys_begin(const std::string &prefix =
std::string()) const; | | Xapian::TermIterator synonym_keys_begin(const std::string &prefix =
std::string()) const; | |
| | | | |
| /// Corresponding end iterator to synonym_keys_begin(prefix). | | /// Corresponding end iterator to synonym_keys_begin(prefix). | |
| Xapian::TermIterator synonym_keys_end(const std::string & = std::str
ing()) const { | | Xapian::TermIterator synonym_keys_end(const std::string & = std::str
ing()) const { | |
|
| return Xapian::TermIterator(NULL); | | return Xapian::TermIterator(); | |
| } | | } | |
| | | | |
| /** Get the user-specified metadata associated with a given key. | | /** Get the user-specified metadata associated with a given key. | |
| * | | * | |
| * User-specified metadata allows you to store arbitrary informatio
n | | * User-specified metadata allows you to store arbitrary informatio
n | |
| * in the form of (key,tag) pairs. See @a | | * in the form of (key,tag) pairs. See @a | |
| * WritableDatabase::set_metadata() for more information. | | * WritableDatabase::set_metadata() for more information. | |
| * | | * | |
| * When invoked on a Xapian::Database object representing multiple | | * When invoked on a Xapian::Database object representing multiple | |
| * databases, currently only the metadata for the first is consider
ed | | * databases, currently only the metadata for the first is consider
ed | |
| | | | |
| skipping to change at line 440 | | skipping to change at line 442 | |
| * | | * | |
| * @exception Xapian::UnimplementedError will be thrown if the | | * @exception Xapian::UnimplementedError will be thrown if the | |
| * backend implements user-specified metadata,
but | | * backend implements user-specified metadata,
but | |
| * doesn't implement iterating its keys (curren
tly | | * doesn't implement iterating its keys (curren
tly | |
| * this happens for the InMemory backend). | | * this happens for the InMemory backend). | |
| */ | | */ | |
| Xapian::TermIterator metadata_keys_begin(const std::string &prefix =
std::string()) const; | | Xapian::TermIterator metadata_keys_begin(const std::string &prefix =
std::string()) const; | |
| | | | |
| /// Corresponding end iterator to metadata_keys_begin(). | | /// Corresponding end iterator to metadata_keys_begin(). | |
| Xapian::TermIterator metadata_keys_end(const std::string & = std::st
ring()) const { | | Xapian::TermIterator metadata_keys_end(const std::string & = std::st
ring()) const { | |
|
| return Xapian::TermIterator(NULL); | | return Xapian::TermIterator(); | |
| } | | } | |
| | | | |
| /** Get a UUID for the database. | | /** Get a UUID for the database. | |
| * | | * | |
| * The UUID will persist for the lifetime of the database. | | * The UUID will persist for the lifetime of the database. | |
| * | | * | |
| * Replicas (eg, made with the replication protocol, or by copying
all | | * Replicas (eg, made with the replication protocol, or by copying
all | |
| * the database files) will have the same UUID. However, copies (m
ade | | * the database files) will have the same UUID. However, copies (m
ade | |
| * with copydatabase, or xapian-compact) will have different UUIDs. | | * with copydatabase, or xapian-compact) will have different UUIDs. | |
| * | | * | |
| | | | |
End of changes. 14 change blocks. |
| 32 lines changed or deleted | | 30 lines changed or added | |
|
| enquire.h | | enquire.h | |
| | | | |
| skipping to change at line 671 | | skipping to change at line 671 | |
| * @param database Specification of the database or databases to | | * @param database Specification of the database or databases to | |
| * use. | | * use. | |
| * @param errorhandler_ A pointer to the error handler to use. | | * @param errorhandler_ A pointer to the error handler to use. | |
| * Ownership of the object pointed to is not assumed by the | | * Ownership of the object pointed to is not assumed by the | |
| * Xapian::Enquire object - the user should delete the | | * Xapian::Enquire object - the user should delete the | |
| * Xapian::ErrorHandler object after the Xapian::Enquire obj
ect | | * Xapian::ErrorHandler object after the Xapian::Enquire obj
ect | |
| * is deleted. To use no error handler, this parameter | | * is deleted. To use no error handler, this parameter | |
| * should be 0. | | * should be 0. | |
| * | | * | |
| * @exception Xapian::InvalidArgumentError will be thrown if an | | * @exception Xapian::InvalidArgumentError will be thrown if an | |
|
| * initialised Database object is supplied. | | * empty Database object is supplied. | |
| */ | | */ | |
| explicit Enquire(const Database &database, ErrorHandler * errorhandl
er_ = 0); | | explicit Enquire(const Database &database, ErrorHandler * errorhandl
er_ = 0); | |
| | | | |
| /** Close the Xapian::Enquire object. | | /** Close the Xapian::Enquire object. | |
| */ | | */ | |
| ~Enquire(); | | ~Enquire(); | |
| | | | |
| /** Set the query to run. | | /** Set the query to run. | |
| * | | * | |
| * @param query the new query to run. | | * @param query the new query to run. | |
| | | | |
| skipping to change at line 1103 | | skipping to change at line 1103 | |
| * even if they do in the query. | | * even if they do in the query. | |
| * | | * | |
| * @exception Xapian::InvalidArgumentError See class documentation
. | | * @exception Xapian::InvalidArgumentError See class documentation
. | |
| * @exception Xapian::DocNotFoundError The document specified | | * @exception Xapian::DocNotFoundError The document specified | |
| * could not be found in the database. | | * could not be found in the database. | |
| */ | | */ | |
| TermIterator get_matching_terms_begin(Xapian::docid did) const; | | TermIterator get_matching_terms_begin(Xapian::docid did) const; | |
| | | | |
| /** End iterator corresponding to get_matching_terms_begin() */ | | /** End iterator corresponding to get_matching_terms_begin() */ | |
| TermIterator get_matching_terms_end(Xapian::docid /*did*/) const { | | TermIterator get_matching_terms_end(Xapian::docid /*did*/) const { | |
|
| return TermIterator(NULL); | | return TermIterator(); | |
| } | | } | |
| | | | |
| /** Get terms which match a given document, by match set item. | | /** Get terms which match a given document, by match set item. | |
| * | | * | |
| * This method returns the terms in the current query which match | | * This method returns the terms in the current query which match | |
| * the given document. | | * the given document. | |
| * | | * | |
| * If the underlying database has suitable support, using this call | | * If the underlying database has suitable support, using this call | |
| * (rather than passing a Xapian::docid) will enable the system to | | * (rather than passing a Xapian::docid) will enable the system to | |
| * ensure that the correct data is returned, and that the document | | * ensure that the correct data is returned, and that the document | |
| | | | |
| skipping to change at line 1132 | | skipping to change at line 1132 | |
| * even if they do in the query. | | * even if they do in the query. | |
| * | | * | |
| * @exception Xapian::InvalidArgumentError See class documentation
. | | * @exception Xapian::InvalidArgumentError See class documentation
. | |
| * @exception Xapian::DocNotFoundError The document specified | | * @exception Xapian::DocNotFoundError The document specified | |
| * could not be found in the database. | | * could not be found in the database. | |
| */ | | */ | |
| TermIterator get_matching_terms_begin(const MSetIterator &it) const; | | TermIterator get_matching_terms_begin(const MSetIterator &it) const; | |
| | | | |
| /** End iterator corresponding to get_matching_terms_begin() */ | | /** End iterator corresponding to get_matching_terms_begin() */ | |
| TermIterator get_matching_terms_end(const MSetIterator &/*it*/) cons
t { | | TermIterator get_matching_terms_end(const MSetIterator &/*it*/) cons
t { | |
|
| return TermIterator(NULL); | | return TermIterator(); | |
| } | | } | |
| | | | |
| /// Return a string describing this object. | | /// Return a string describing this object. | |
| std::string get_description() const; | | std::string get_description() const; | |
| }; | | }; | |
| | | | |
| // Deprecated forms: | | // Deprecated forms: | |
| | | | |
| inline void | | inline void | |
| Enquire::set_sort_by_value(Xapian::valueno sort_key) | | Enquire::set_sort_by_value(Xapian::valueno sort_key) | |
| | | | |
End of changes. 3 change blocks. |
| 3 lines changed or deleted | | 3 lines changed or added | |
|
| matchspy.h | | matchspy.h | |
| | | | |
| skipping to change at line 213 | | skipping to change at line 213 | |
| * | | * | |
| * Items will be returned in ascending alphabetical order. | | * Items will be returned in ascending alphabetical order. | |
| * | | * | |
| * During the iteration, the frequency of the current value can be | | * During the iteration, the frequency of the current value can be | |
| * obtained with the get_termfreq() method on the iterator. | | * obtained with the get_termfreq() method on the iterator. | |
| */ | | */ | |
| TermIterator values_begin() const; | | TermIterator values_begin() const; | |
| | | | |
| /** End iterator corresponding to values_begin() */ | | /** End iterator corresponding to values_begin() */ | |
| TermIterator values_end() const { | | TermIterator values_end() const { | |
|
| return TermIterator(NULL); | | return TermIterator(); | |
| } | | } | |
| | | | |
| /** Get an iterator over the most frequent values seen in the slot. | | /** Get an iterator over the most frequent values seen in the slot. | |
| * | | * | |
| * Items will be returned in descending order of frequency. Values wi
th | | * Items will be returned in descending order of frequency. Values wi
th | |
| * the same frequency will be returned in ascending alphabetical order
. | | * the same frequency will be returned in ascending alphabetical order
. | |
| * | | * | |
| * During the iteration, the frequency of the current value can be | | * During the iteration, the frequency of the current value can be | |
| * obtained with the get_termfreq() method on the iterator. | | * obtained with the get_termfreq() method on the iterator. | |
| * | | * | |
| * @param maxvalues The maximum number of values to return. | | * @param maxvalues The maximum number of values to return. | |
| */ | | */ | |
| TermIterator top_values_begin(size_t maxvalues) const; | | TermIterator top_values_begin(size_t maxvalues) const; | |
| | | | |
| /** End iterator corresponding to top_values_begin() */ | | /** End iterator corresponding to top_values_begin() */ | |
| TermIterator top_values_end(size_t) const { | | TermIterator top_values_end(size_t) const { | |
|
| return TermIterator(NULL); | | return TermIterator(); | |
| } | | } | |
| | | | |
| /** Implementation of virtual operator(). | | /** Implementation of virtual operator(). | |
| * | | * | |
| * This implementation tallies values for a matching document. | | * This implementation tallies values for a matching document. | |
| */ | | */ | |
| void operator()(const Xapian::Document &doc, Xapian::weight wt); | | void operator()(const Xapian::Document &doc, Xapian::weight wt); | |
| | | | |
| virtual MatchSpy * clone() const; | | virtual MatchSpy * clone() const; | |
| virtual std::string name() const; | | virtual std::string name() const; | |
| | | | |
End of changes. 2 change blocks. |
| 2 lines changed or deleted | | 2 lines changed or added | |
|
| queryparser.h | | queryparser.h | |
| | | | |
| skipping to change at line 571 | | skipping to change at line 571 | |
| * | | * | |
| * If you call @c add_prefix() and @c add_boolean_prefix() for the | | * If you call @c add_prefix() and @c add_boolean_prefix() for the | |
| * same value of @a field, a @c Xapian::InvalidOperationError exceptio
n | | * same value of @a field, a @c Xapian::InvalidOperationError exceptio
n | |
| * will be thrown. | | * will be thrown. | |
| * | | * | |
| * In 1.0.3 and earlier, subsequent calls to this method with the same | | * In 1.0.3 and earlier, subsequent calls to this method with the same | |
| * value of @a field had no effect. | | * value of @a field had no effect. | |
| * | | * | |
| * @param field The user visible field name | | * @param field The user visible field name | |
| * @param prefix The term prefix to map this to | | * @param prefix The term prefix to map this to | |
|
| * @param exclusive If true, each document can have at most one value | | * @param exclusive If true, each document can have at most one term w | |
| of | | ith | |
| * the field, so Xapian should combine multiple values | | * this prefix, so multiple filters with this prefix | |
| * with OP_OR. If false, each document can have multi | | * should be combined with OP_OR. If false, each | |
| ple | | * document can have multiple terms with this prefix, | |
| * values of the field, so Xapian combine them with | | so | |
| * OP_AND, as we would with filters with different | | * multiple filters should be combined with OP_AND, li | |
| * prefixes. [default: true] | | ke | |
| | | * happens with filters with different prefixes. | |
| | | * [default: true] | |
| */ | | */ | |
| void add_boolean_prefix(const std::string &field, const std::string &pr
efix, | | void add_boolean_prefix(const std::string &field, const std::string &pr
efix, | |
| bool exclusive); | | bool exclusive); | |
| | | | |
| /* FIXME:1.3: Merge two versions into one with optional parameter | | /* FIXME:1.3: Merge two versions into one with optional parameter | |
| * "exclusive", default true. */ | | * "exclusive", default true. */ | |
| void add_boolean_prefix(const std::string &field, const std::string &pr
efix); | | void add_boolean_prefix(const std::string &field, const std::string &pr
efix); | |
| | | | |
| /// Iterate over terms omitted from the query as stopwords. | | /// Iterate over terms omitted from the query as stopwords. | |
| TermIterator stoplist_begin() const; | | TermIterator stoplist_begin() const; | |
| TermIterator stoplist_end() const { | | TermIterator stoplist_end() const { | |
|
| return TermIterator(NULL); | | return TermIterator(); | |
| } | | } | |
| | | | |
| /// Iterate over unstemmed forms of the given (stemmed) term used in th
e query. | | /// Iterate over unstemmed forms of the given (stemmed) term used in th
e query. | |
| TermIterator unstem_begin(const std::string &term) const; | | TermIterator unstem_begin(const std::string &term) const; | |
| TermIterator unstem_end(const std::string &) const { | | TermIterator unstem_end(const std::string &) const { | |
|
| return TermIterator(NULL); | | return TermIterator(); | |
| } | | } | |
| | | | |
| /// Register a ValueRangeProcessor. | | /// Register a ValueRangeProcessor. | |
| void add_valuerangeprocessor(Xapian::ValueRangeProcessor * vrproc); | | void add_valuerangeprocessor(Xapian::ValueRangeProcessor * vrproc); | |
| | | | |
| /** Get the spelling-corrected query string. | | /** Get the spelling-corrected query string. | |
| * | | * | |
| * This will only be set if FLAG_SPELLING_CORRECTION is specified when | | * This will only be set if FLAG_SPELLING_CORRECTION is specified when | |
| * QueryParser::parse_query() was last called. | | * QueryParser::parse_query() was last called. | |
| * | | * | |
| | | | |
End of changes. 3 change blocks. |
| 10 lines changed or deleted | | 12 lines changed or added | |
|
| termgenerator.h | | termgenerator.h | |
| | | | |
| skipping to change at line 104 | | skipping to change at line 104 | |
| * | | * | |
| * @param toggle Flags to XOR. | | * @param toggle Flags to XOR. | |
| * @param mask Flags to AND with first. | | * @param mask Flags to AND with first. | |
| * | | * | |
| * @return The old flags setting. | | * @return The old flags setting. | |
| */ | | */ | |
| flags set_flags(flags toggle, flags mask = flags(0)); | | flags set_flags(flags toggle, flags mask = flags(0)); | |
| | | | |
| /** Index some text. | | /** Index some text. | |
| * | | * | |
|
| * @param weight The wdf increment (default 1). | | * @param wdf_inc The wdf increment (default 1). | |
| * @param prefix The term prefix to use (default is no prefix). | | * @param prefix The term prefix to use (default is no prefix). | |
| */ | | */ | |
| void index_text(const Xapian::Utf8Iterator & itor, | | void index_text(const Xapian::Utf8Iterator & itor, | |
|
| Xapian::termcount weight = 1, | | Xapian::termcount wdf_inc = 1, | |
| const std::string & prefix = std::string()); | | const std::string & prefix = std::string()); | |
| | | | |
| /** Index some text in a std::string. | | /** Index some text in a std::string. | |
| * | | * | |
|
| * @param weight The wdf increment (default 1). | | * @param wdf_inc The wdf increment (default 1). | |
| * @param prefix The term prefix to use (default is no prefix). | | * @param prefix The term prefix to use (default is no prefix). | |
| */ | | */ | |
| void index_text(const std::string & text, | | void index_text(const std::string & text, | |
|
| Xapian::termcount weight = 1, | | Xapian::termcount wdf_inc = 1, | |
| const std::string & prefix = std::string()) { | | const std::string & prefix = std::string()) { | |
|
| return index_text(Utf8Iterator(text), weight, prefix); | | return index_text(Utf8Iterator(text), wdf_inc, prefix); | |
| } | | } | |
| | | | |
| /** Index some text without positional information. | | /** Index some text without positional information. | |
| * | | * | |
| * Just like index_text, but no positional information is generated. T
his | | * Just like index_text, but no positional information is generated. T
his | |
| * means that the database will be significantly smaller, but that phra
se | | * means that the database will be significantly smaller, but that phra
se | |
| * searching and NEAR won't be supported. | | * searching and NEAR won't be supported. | |
| */ | | */ | |
| void index_text_without_positions(const Xapian::Utf8Iterator & itor, | | void index_text_without_positions(const Xapian::Utf8Iterator & itor, | |
|
| Xapian::termcount weight = 1, | | Xapian::termcount wdf_inc = 1, | |
| const std::string & prefix = std::stri
ng()); | | const std::string & prefix = std::stri
ng()); | |
| | | | |
| /** Index some text in a std::string without positional information. | | /** Index some text in a std::string without positional information. | |
| * | | * | |
| * Just like index_text, but no positional information is generated. T
his | | * Just like index_text, but no positional information is generated. T
his | |
| * means that the database will be significantly smaller, but that phra
se | | * means that the database will be significantly smaller, but that phra
se | |
| * searching and NEAR won't be supported. | | * searching and NEAR won't be supported. | |
| */ | | */ | |
| void index_text_without_positions(const std::string & text, | | void index_text_without_positions(const std::string & text, | |
|
| Xapian::termcount weight = 1, | | Xapian::termcount wdf_inc = 1, | |
| const std::string & prefix = std::stri
ng()) { | | const std::string & prefix = std::stri
ng()) { | |
|
| return index_text_without_positions(Utf8Iterator(text), weight, pref
ix); | | return index_text_without_positions(Utf8Iterator(text), wdf_inc, pre
fix); | |
| } | | } | |
| | | | |
| /** Increase the termpos used by index_text by @a delta. | | /** Increase the termpos used by index_text by @a delta. | |
| * | | * | |
| * This can be used to prevent phrase searches from spanning two | | * This can be used to prevent phrase searches from spanning two | |
| * unconnected blocks of text (e.g. the title and body text). | | * unconnected blocks of text (e.g. the title and body text). | |
| */ | | */ | |
| void increase_termpos(Xapian::termcount delta = 100); | | void increase_termpos(Xapian::termcount delta = 100); | |
| | | | |
| /// Get the current term position. | | /// Get the current term position. | |
| | | | |
End of changes. 8 change blocks. |
| 8 lines changed or deleted | | 8 lines changed or added | |
|