Changeset 1324 for trunk/gsdl/src/colservr/mgsearch.cpp
- Timestamp:
- 2000-08-02T12:58:29+12:00 (24 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/gsdl/src/colservr/mgsearch.cpp
r1306 r1324 232 232 233 233 mgsearchclass::mgsearchclass () 234 {235 cache = new querycache (RESULTCACHESIZE);234 : searchclass() { 235 236 236 } 237 237 … … 243 243 cache = NULL; 244 244 } 245 }246 247 248 void mgsearchclass::setcollectdir (const text_t &thecollectdir)249 {250 collectdir = thecollectdir;251 245 } 252 246 … … 308 302 bool mgsearchclass::search(const queryparamclass &queryparams, 309 303 queryresultsclass &queryresults) { 310 assert (cache != NULL);304 // assert (cache != NULL); 311 305 312 306 queryresults.clear(); 313 307 cerr << "mgsearch start of search"<<endl; 314 308 // first check the cache 315 if (cache->find(queryparams, queryresults)) return true; 316 309 if (cache != NULL) { 310 if (cache->find(queryparams, queryresults)) return true; 311 } 317 312 // make sure there is a query to be processed 318 313 if (!has_unicode_letdig(queryparams.querystring)) return true; … … 320 315 if (makeindexcurrent (queryparams.index, queryparams.subcollection, 321 316 queryparams.language, queryparams.collection)) { 317 cerr << "made index current "<<endl; 322 318 setsearchmode (queryparams); 323 319 submitquery (queryparams); 324 320 getresults (queryparams, queryresults); 321 cerr << "got results"<<endl; 325 322 return true; 326 323 } … … 512 509 return (bool)databaseloaded; 513 510 } 511
Note:
See TracChangeset
for help on using the changeset viewer.