const parameters to Rdb::getListSize() (and removed unused overload)

This commit is contained in:
Ivan Skytte Jørgensen
2016-10-17 12:19:01 +02:00
parent 240c8da792
commit f2b8058f8d
2 changed files with 4 additions and 10 deletions

@ -2134,7 +2134,7 @@ bool Rdb::addRecord(collnum_t collnum, char *key, char *data, int32_t dataSize)
// . use the maps and tree to estimate the size of this list w/o hitting disk
// . used by Indexdb.cpp to get the size of a list for IDF weighting purposes
int64_t Rdb::getListSize(collnum_t collnum, char *startKey, char *endKey, char *max, int64_t oldTruncationLimit) {
int64_t Rdb::getListSize(collnum_t collnum, const char *startKey, const char *endKey, char *max, int64_t oldTruncationLimit) {
// pick it
if ( collnum < 0 || collnum > getNumBases() || ! getBase(collnum) ) {
log(LOG_WARN, "db: %s bad collnum of %i", m_dbname, collnum);

12
Rdb.h

@ -193,15 +193,9 @@ public:
}
// use the maps and tree to estimate the size of this list
int64_t getListSize ( collnum_t collnum,
char *startKey ,char *endKey , char *maxKey ,
int64_t oldTruncationLimit ) ;
int64_t getListSize ( collnum_t collnum,
key96_t startKey ,key96_t endKey , key96_t *maxKey ,
int64_t oldTruncationLimit ) {
return getListSize(collnum,(char *)&startKey,(char *)&endKey,
(char *)maxKey,oldTruncationLimit);}
int64_t getListSize(collnum_t collnum,
const char *startKey, const char *endKey, char *maxKey,
int64_t oldTruncationLimit);
// positive minus negative
int64_t getNumTotalRecs ( bool useCache = false ) ;