Changeset 13982


Ignore:
Timestamp:
2007-03-15T13:21:55+13:00 (17 years ago)
Author:
lh92
Message:

Added UseBook variable for Realistic Book

Location:
trunk/gsdl
Files:
8 edited

Legend:

Unmodified
Added
Removed
  • trunk/gsdl/macros/pref.dm

    r13971 r13982  
    569569
    570570<tr>_formatoption_</tr>
    571 <tr>_bookoption_</tr>
     571_If_("_tidyoption_" ne "untidy",<tr>_bookoption_</tr>)
    572572</table>
    573573</blockquote>
  • trunk/gsdl/src/colservr/collectserver.cpp

    r12867 r13982  
    6161// configure should be called for each line in the
    6262// configuration files to configure the collection server and everything
    63 // it contains. The configuration should take place just before initialisation.
     63// it contains. The configuration should take place just before initialisationhttps://www.google.com/accounts/ServiceLogin?service=mail&passive=true&rm=false&continue=http%3A%2F%2Fmail.google.com%2Fmail%3Fui%3Dhtml%26zy%3Dl&ltmpl=ca_tlsosm_video&ltmplcache=2&hl=en.
    6464void collectserver::configure (const text_t &key, const text_tarray &cfgline) {
    6565  if (cfgline.size() >= 1) {
    6666    const text_t &value = cfgline[0];
    67     if (key == "gsdlhome") configinfo.gsdlhome = value;
     67    if (key == "plugin")
     68    {
     69        //get the plugin name
     70    const text_t &name = cfgline[0];
     71   
     72    if (name == "HTMLPlug")
     73    {
     74        for (int hI = 1; hI < cfgline.size(); hI++)
     75        {
     76            const text_t &plugOption = cfgline[hI];
     77           
     78            if (plugOption == "-tidy_html")
     79            {
     80                collectinfo.useBook = true;
     81                break;
     82            }
     83        }
     84    }
     85    }
     86    else if (key == "gsdlhome") configinfo.gsdlhome = value;
    6887    else if (key == "gdbmhome") configinfo.gdbmhome = value;
    6988    else if (key == "collection") {
     
    143162      text_tmap params_map = collectinfo.collection_macros[meta_name];
    144163     
    145       if (cfgline.size() == 2) {// no params for this macro
     164      if (cfgline.size() == 2) {// no params for this macrohttp://uk.sports.yahoo.com/13032007/13/news-brief.html
    146165    params_map[g_EmptyText] = cfgline[1];
    147166      }
  • trunk/gsdl/src/colservr/corbaServer.mpp

    r8186 r13982  
    268268    cout << "NumBytes  = " << response.numBytes << endl;
    269269    cout << "NumWords  = " << response.numWords << endl;
    270 
     270    cout << "UseBook   = " << ((response.useBook)  ?"True":"False") << endl;
     271   
     272    corbaResponse.useBook   = response.useBook;
    271273    corbaResponse.isPublic  = response.isPublic;
    272274    corbaResponse.isBeta    = response.isBeta;
  • trunk/gsdl/src/colservr/z3950explain.cpp

    r10437 r13982  
    101101    docinfo.metadata["isBeta"].values.push_back("false");
    102102      }
     103      if (collectinfo.useBook == true) {
     104    docinfo.metadata["useBook"].values.push_back("true");
     105      } else {
     106    docinfo.metadata["useBook"].values.push_back("false");
     107      }
    103108      docinfo.metadata["buildDate"].values.push_back(collectinfo.buildDate);
    104109      text_tarray::iterator TEXTT_HERE = collectinfo.ccsCols.begin();
  • trunk/gsdl/src/recpt/comtypes.cpp

    r12863 r13982  
    5151void ColInfoResponse_t::clear () {
    5252  shortInfo.clear();
     53  useBook=false;
    5354  isPublic=true;
    5455  isBeta=false;
  • trunk/gsdl/src/recpt/comtypes.h

    r12863 r13982  
    8484 
    8585  ShortColInfo_t shortInfo;
     86  bool useBook; //whether we want to display the book
    8687  bool isPublic;
    8788  bool isBeta;
  • trunk/gsdl/src/recpt/corbaproto.mpp

    r2261 r13982  
    582582
    583583  // convert the response back to normal form
     584  collectinfo.useBook = corbaCollectInfo.useBook;
    584585  collectinfo.isPublic = corbaCollectInfo.isPublic;
    585586  collectinfo.isBeta   = corbaCollectInfo.isBeta;
  • trunk/gsdl/src/recpt/pageaction.cpp

    r13967 r13982  
    638638    cinfo = recpt->get_collectinfo_ptr (collectproto, arg_c, logout);
    639639   
     640    //set the tidyoption
     641    if (cinfo->useBook == false)
     642    {
     643        disp.setmacro ("tidyoption", displayclass::defaultpackage, "untidy");
     644    }
     645    else
     646    {
     647        disp.setmacro ("tidyoption", displayclass::defaultpackage, "tidy");
     648    }
     649   
    640650    disp.setmacro ("numdocs", displayclass::defaultpackage, cinfo->numDocs);
    641651    disp.setmacro ("numsections", displayclass::defaultpackage, cinfo->numSections);
Note: See TracChangeset for help on using the changeset viewer.