OpenTREP Logo  0.6.0
C++ Open Travel Request Parsing Library
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
OPENTREP::ResultHolder Class Reference

Class wrapping functions on a list of Result objects. More...

#include <opentrep/bom/ResultHolder.hpp>

+ Inheritance diagram for OPENTREP::ResultHolder:

Public Member Functions

const TravelQuery_TgetQueryString () const
 
const ResultList_TgetResultList () const
 
const Percentage_TgetCombinedWeight () const
 
StringSet getCorrectedStringSet () const
 
void setCombinedWeight (const Percentage_T &iPercentage)
 
void displayXapianPercentages () const
 
void calculateEnvelopeWeights () const
 
void calculateCodeMatches () const
 
void calculatePageRanks () const
 
void calculateHeuristicWeights () const
 
void calculateCombinedWeights ()
 
void toStream (std::ostream &) const
 
void fromStream (std::istream &)
 
std::string toString () const
 
std::string describeKey () const
 
std::string describeShortKey () const
 

Friends

class FacResultCombination
 
class FacResultHolder
 

Detailed Description

Class wrapping functions on a list of Result objects.

Definition at line 26 of file ResultHolder.hpp.

Member Function Documentation

const TravelQuery_T& OPENTREP::ResultHolder::getQueryString ( ) const
inline

Get the query string.

Definition at line 34 of file ResultHolder.hpp.

const ResultList_T& OPENTREP::ResultHolder::getResultList ( ) const
inline

Retrieve the list of result objects.

Definition at line 41 of file ResultHolder.hpp.

Referenced by OPENTREP::createPlaces().

const Percentage_T& OPENTREP::ResultHolder::getCombinedWeight ( ) const
inline

Get the combined weight, for all the rules (full-text, PageRank, etc)

Definition at line 48 of file ResultHolder.hpp.

Referenced by OPENTREP::ResultCombination::chooseBestMatchingResultHolder(), and OPENTREP::ResultCombination::getBestMatchingWeight().

StringSet OPENTREP::ResultHolder::getCorrectedStringSet ( ) const

Get the list of corrected strings

Definition at line 78 of file ResultHolder.cpp.

References OPENTREP::Result::getCorrectedTravelQuery(), and OPENTREP::StringSet::push_back().

Referenced by OPENTREP::ResultCombination::getCorrectedStringSet().

void OPENTREP::ResultHolder::setCombinedWeight ( const Percentage_T iPercentage)
inline

Set the combined weight, for all the rules (full-text, PageRank, etc)

Definition at line 63 of file ResultHolder.hpp.

Referenced by calculateCombinedWeights().

void OPENTREP::ResultHolder::displayXapianPercentages ( ) const

Display the Xapian matching percentages for all the matching documents.

Definition at line 96 of file ResultHolder.cpp.

References OPENTREP::Result::displayXapianPercentages().

Referenced by OPENTREP::ResultCombination::displayXapianPercentages().

void OPENTREP::ResultHolder::calculateEnvelopeWeights ( ) const

Calculate/set the envelope weights for all the matching documents

Definition at line 109 of file ResultHolder.cpp.

References OPENTREP::Result::calculateEnvelopeWeights().

Referenced by OPENTREP::ResultCombination::calculateEnvelopeWeights().

void OPENTREP::ResultHolder::calculateCodeMatches ( ) const

Calculate/set the IATA/ICAO code matching weights for all the matching documents

Definition at line 122 of file ResultHolder.cpp.

References OPENTREP::Result::calculateCodeMatches().

Referenced by OPENTREP::ResultCombination::calculateCodeMatches().

void OPENTREP::ResultHolder::calculatePageRanks ( ) const

Calculate/set the PageRanks for all the matching documents

Definition at line 135 of file ResultHolder.cpp.

References OPENTREP::Result::calculatePageRanks().

Referenced by OPENTREP::ResultCombination::calculatePageRanks().

void OPENTREP::ResultHolder::calculateHeuristicWeights ( ) const

Calculate/set the heuristic weights for all the matching documents

Definition at line 148 of file ResultHolder.cpp.

References OPENTREP::Result::calculateHeuristicWeights().

Referenced by OPENTREP::ResultCombination::calculateHeuristicWeights().

void OPENTREP::ResultHolder::calculateCombinedWeights ( )
void OPENTREP::ResultHolder::toStream ( std::ostream &  ioOut) const
virtual

Dump a Business Object into an output stream.

Parameters
ostream&the output stream.

Implements OPENTREP::BomAbstract.

Definition at line 69 of file ResultHolder.cpp.

References toString().

void OPENTREP::ResultHolder::fromStream ( std::istream &  ioIn)
virtual

Read a Business Object from an input stream.

Parameters
istream&the input stream.

Implements OPENTREP::BomAbstract.

Definition at line 74 of file ResultHolder.cpp.

std::string OPENTREP::ResultHolder::toString ( ) const
virtual

Get the serialised version of the Business Object.

Implements OPENTREP::BomAbstract.

Definition at line 49 of file ResultHolder.cpp.

References describeShortKey(), and OPENTREP::Result::toString().

Referenced by OPENTREP::searchString(), toStream(), and OPENTREP::ResultCombination::toString().

std::string OPENTREP::ResultHolder::describeKey ( ) const
virtual

Get a string describing the whole key (differentiating two objects at any level).

Implements OPENTREP::BomAbstract.

Definition at line 44 of file ResultHolder.cpp.

References describeShortKey().

Referenced by calculateCombinedWeights(), and OPENTREP::ResultCombination::chooseBestMatchingResultHolder().

std::string OPENTREP::ResultHolder::describeShortKey ( ) const
virtual

Get a string describing the short key (differentiating two objects at the same level).

Implements OPENTREP::BomAbstract.

Definition at line 37 of file ResultHolder.cpp.

Referenced by OPENTREP::chooseBestMatchingResultHolder(), describeKey(), and toString().

Friends And Related Function Documentation

friend class FacResultCombination
friend

Definition at line 27 of file ResultHolder.hpp.

friend class FacResultHolder
friend

Definition at line 28 of file ResultHolder.hpp.


The documentation for this class was generated from the following files: