Concordia
ConcordiaSearchResult Class Reference

#include <concordia_search_result.hpp>

Public Member Functions

 ConcordiaSearchResult (TokenizedSentence tokenizedPattern)
 
virtual ~ConcordiaSearchResult ()
 
void addFragment (const MatchedPatternFragment &fragment)
 
void sortFragments ()
 
void computeBestOverlay ()
 
TokenizedSentence getTokenizedPattern () const
 
std::vector< MatchedPatternFragmentgetFragments () const
 
std::vector< MatchedPatternFragmentgetBestOverlay () const
 
double getBestOverlayScore () const
 

Detailed Description

Class representing result of concordia search. Contains the following information:

  • tokenized pattern which was used for searching
  • list of longest matched fragments sorted in descending order by length
  • the best overlay
  • the score of the best overlay.

For more info about concordia searching see Concordia searching.

Constructor & Destructor Documentation

ConcordiaSearchResult::ConcordiaSearchResult ( TokenizedSentence  tokenizedPattern)
explicit

Constructor.

Parameters
tokenVectortokenized pattern which was used for searching
ConcordiaSearchResult::~ConcordiaSearchResult ( )
virtual

Destructor.

Member Function Documentation

void ConcordiaSearchResult::addFragment ( const MatchedPatternFragment fragment)

Adds a matched pattern fragment to the list.

Parameters
fragmentfragment to be added
void ConcordiaSearchResult::computeBestOverlay ( )

Computes the best overlay by choosing appropriate fragments from the fragments list. For more info see Concordia searching.

Here is the call graph for this function:

std::vector<MatchedPatternFragment> ConcordiaSearchResult::getBestOverlay ( ) const
inline

Getter for best overlay.

Returns
list of fragments that comprise the best overlay
double ConcordiaSearchResult::getBestOverlayScore ( ) const
inline

Getter for best overlay score.

Returns
score of the best overlay
std::vector<MatchedPatternFragment> ConcordiaSearchResult::getFragments ( ) const
inline

Getter for all matched pattern fragments list.

Returns
matched pattern fragments list
TokenizedSentence ConcordiaSearchResult::getTokenizedPattern ( ) const
inline

Getter for tokenized pattern.

Returns
tokenized search pattern
void ConcordiaSearchResult::sortFragments ( )

Sorts the list of matched pattern fragments in descending order by length.


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