[Xapian-devel] docid type redifine

Pronichev Alexander dyker at agava.com
Wed Jul 20 09:11:06 BST 2005

Hello all.
I need to redefine a docid type (and all dependent types) like this: typedef unsigned long long docid;
I think it would be enough to edit "include/xapian/types.h", but it isn't so.
1) I've added :

om_tostring(unsigned long long val)
in common/utils.{h,cc}

2) In include/enquire.h (line 438) I've found the following declaration:
ESetIterator operator[](Xapian::doccount i) const;
but I think it would be 
ESetIterator operator[](Xapian::termcount i) const;
isn't it?

Then I have the following errors while compiling backends:

quartz_postlist.cc: In constructor `
   Xapian::Database::Internal>, const Btree*, const Btree*, const std::string&)
quartz_postlist.cc:673: error: cannot convert `doccount*' to `termcount*' for 
   argument `3' to `docid read_start_of_first_chunk(const char**, const char*, 
   termcount*, termcount*)'

so I have a question: what is function static Xapian::docid read_start_of_first_chunk(...) for? (actually I don't understand what is "posting list"). Must the 3rd parameter be Xapian::doccount instead of Xapian::termcount? Or maybe QuartzPostList::number_of_entries class property must be Xapian::termcount instead of Xapian::doccount?

WBR dyker
Agava Software

More information about the Xapian-devel mailing list