pike.git / lib / modules / Search.pmod / Query.pmod

version» Context lines:

pike.git/lib/modules/Search.pmod/Query.pmod:111:   //! @elem array(mapping) 2   //! All wanted globs in the query. (I.e. not the globs that were   //! preceded by minus.)   //! @endarray   //!   array(Search.ResultSet|array(string)) execute(Search.Database.Base db,    Search.Grammar.AbstractParser parser,    string query,    Search.RankingProfile ranking,    void|array(string) stop_words, -  void|search_order order) +  search_order order=RELEVANCE)   {    Search.Grammar.ParseNode q = parser->parse(query);    if (stop_words && sizeof(stop_words))    Search.Grammar.remove_stop_words(q, stop_words);       q = Search.Grammar.optimize(q);       if (!q) // The query was a null query    return ({ Search.ResultSet(), ({}), ({}) }); // so return an empty resultset   
pike.git/lib/modules/Search.pmod/Query.pmod:451:    break;    default:    error("Unknown type of ParseNode!");    } // switch (q->op)    }       } (db, ranking)->execute(q);       res[0] -= db->get_deleted_documents();    -  if(!order) -  order = RELEVANCE; -  +     if(order!=NONE)    switch(order)    {    case RELEVANCE:    res[0]->sort();    break;    case DATE_ASC:    case DATE_DESC:    res[0] = res[0]->finalize()->add_ranking(db->get_global_dateset());    if(order==DATE_DESC)