Changeset 12380
- Timestamp:
- 2006-08-02T16:30:23+12:00 (18 years ago)
- Location:
- trunk/gsdl
- Files:
-
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/gsdl/macros/english.dm
r12176 r12380 316 316 )} 317 317 _textinvalidquery_ {Invalid query syntax} 318 _textstopwordsmsg_ {The following words are too common and were ignored: } 318 319 319 320 _textmorethan_ {More than } -
trunk/gsdl/src/colservr/expat_resultset.cpp
r12262 r12380 51 51 termfreqobj.termfreq = atoi(term_frequency_str); 52 52 queryresult_ptr->orgterms.push_back(termfreqobj); 53 } 54 55 if (element_name == "StopWord") { 56 char* stop_word_value_str = get_attribute(attributes, "value"); 57 queryresult_ptr->stopwords.insert((text_t) stop_word_value_str); 53 58 } 54 59 -
trunk/gsdl/src/colservr/lucenequeryfilter.cpp
r9620 r12380 238 238 ++terms_here; 239 239 } 240 241 // add the stop words 242 text_tset::iterator stopwords_here = queryresults.stopwords.begin(); 243 text_tset::iterator stopwords_end = queryresults.stopwords.end(); 244 while (stopwords_here != stopwords_end) { 245 response.stopwords.insert(*stopwords_here); 246 ++stopwords_here; 247 } 240 248 } 241 249 … … 367 375 ++termvar_here; 368 376 } 377 378 // add the stop words 379 text_tset::iterator stopwords_here = thisqueryresults.stopwords.begin(); 380 text_tset::iterator stopwords_end = thisqueryresults.stopwords.end(); 381 while (stopwords_here != stopwords_end) { 382 multiresults.stopwords.insert(*stopwords_here); 383 ++stopwords_here; 384 } 369 385 } 370 386 -
trunk/gsdl/src/colservr/queryinfo.h
r12276 r12380 176 176 termfreqclassarray terms; 177 177 text_tset termvariants; 178 178 text_tset stopwords; 179 179 180 void clear (); 180 181 queryresultsclass &operator=(const queryresultsclass &q); -
trunk/gsdl/src/recpt/comtypes.cpp
r11985 r12380 267 267 termInfo.erase (termInfo.begin(), termInfo.end()); 268 268 docInfo.erase (docInfo.begin(), docInfo.end()); 269 stopwords.clear(); 269 270 } 270 271 … … 274 275 termInfo = x.termInfo; 275 276 docInfo = x.docInfo; 277 stopwords = x.stopwords; 276 278 return *this; 277 279 } -
trunk/gsdl/src/recpt/comtypes.h
r11985 r12380 332 332 TermInfo_tarray termInfo; // empty if not requested 333 333 ResultDocInfo_tarray docInfo; // empty if not requested 334 text_tset stopwords; 334 335 335 336 FilterResponse_t &operator=(const FilterResponse_t &x); -
trunk/gsdl/src/recpt/queryaction.cpp
r12276 r12380 1225 1225 ++this_term; 1226 1226 } 1227 1227 1228 1228 if (response.numDocs > 0) { 1229 1229 numdocs += response.numDocs; … … 1578 1578 // define_single_query_macros sets the extra macros for search_single_coll 1579 1579 // that couldn't be set until the query had been done. Those macros are 1580 // _freqmsg_ ,1580 // _freqmsg_ and _stopwordsmsg_ 1581 1581 void queryaction::define_single_query_macros (cgiargsclass &args, 1582 1582 displayclass &disp, 1583 1583 const FilterResponse_t &response) { 1584 // set up _freqmsg_ macros1584 // set up _freqmsg_ and _stopwordsmsg_ macros 1585 1585 1586 1586 text_t freqmsg = ""; … … 1594 1594 ++this_term; 1595 1595 } 1596 1597 1596 disp.setmacro ("freqmsg", "query", freqmsg); 1597 1598 text_t stopwordsmsg = "_textstopwordsmsg_ "; 1599 text_tset::const_iterator stopwords_iterator = response.stopwords.begin(); 1600 while (stopwords_iterator != response.stopwords.end()) { 1601 if (stopwordsmsg != "_textstopwordsmsg_ ") { 1602 stopwordsmsg += ", "; 1603 } 1604 stopwordsmsg += (*stopwords_iterator); 1605 ++stopwords_iterator; 1606 } 1607 disp.setmacro("stopwordsmsg", "query", stopwordsmsg); 1598 1608 } 1599 1609
Note:
See TracChangeset
for help on using the changeset viewer.