[Xapian-devel] Bindings and overloading

Olly Betts olly at survex.com
Thu Jun 3 15:38:45 BST 2004


On Thu, Jun 03, 2004 at 03:25:57PM +0100, James Aylett wrote:
> (Also, it works on vector<Query*> not vector<string&>, so you'd need
> to do something horrible like:

The C++ template version isn't specific to vector<> or Query* - it
just relies on the iterators being inputiterators (I think) and
calls add_subquery() with the dereferenced iterator so as the
documentation says:

  The iterators may be to Xapian::Query objects, pointers to
  Xapian::Query objects, or termnames (std::string-s).

So if possible, we ought to wrap this so it works with strings without
having to explicitly build Xapian::Query objects from them first.

Cheers,
  Olly




More information about the Xapian-devel mailing list