Moses::TargetPhraseCollection Class Reference

a list of target phrases that is translated from the same source phrase More...

#include <TargetPhraseCollection.h>

List of all members.

Public Types

typedef std::vector
< TargetPhrase * >::iterator 
iterator
typedef std::vector
< TargetPhrase * >
::const_iterator 
const_iterator

Public Member Functions

iterator begin ()
iterator end ()
const_iterator begin () const
const_iterator end () const
 ~TargetPhraseCollection ()
const std::vector
< TargetPhrase * > & 
GetCollection () const
void NthElement (size_t tableLimit)
 divide collection into 2 buckets using std::nth_element, the top & bottom according to table limit
size_t GetSize () const
 number of target phrases in this collection
bool IsEmpty () const
 wether collection has any phrases
void Add (TargetPhrase *targetPhrase)
 add a new entry into collection
void Prune (bool adhereTableLimit, size_t tableLimit)
void Sort (bool adhereTableLimit, size_t tableLimit)

Protected Attributes

std::vector< TargetPhrase * > m_collection


Detailed Description

a list of target phrases that is translated from the same source phrase

Definition at line 33 of file TargetPhraseCollection.h.


Member Typedef Documentation

Definition at line 41 of file TargetPhraseCollection.h.

Definition at line 40 of file TargetPhraseCollection.h.


Constructor & Destructor Documentation

Moses::TargetPhraseCollection::~TargetPhraseCollection (  )  [inline]

Definition at line 56 of file TargetPhraseCollection.h.

References m_collection, and Moses::RemoveAllInColl().

Here is the call graph for this function:


Member Function Documentation

void Moses::TargetPhraseCollection::Add ( TargetPhrase targetPhrase  )  [inline]

const_iterator Moses::TargetPhraseCollection::begin (  )  const [inline]

Definition at line 49 of file TargetPhraseCollection.h.

References m_collection.

iterator Moses::TargetPhraseCollection::begin (  )  [inline]

const_iterator Moses::TargetPhraseCollection::end (  )  const [inline]

Definition at line 52 of file TargetPhraseCollection.h.

References m_collection.

iterator Moses::TargetPhraseCollection::end (  )  [inline]

Definition at line 46 of file TargetPhraseCollection.h.

References m_collection.

Referenced by Moses::DecodeStepTranslation::Process(), and Moses::DecodeStepTranslation::ProcessInitialTranslation().

Here is the caller graph for this function:

const std::vector<TargetPhrase*>& Moses::TargetPhraseCollection::GetCollection (  )  const [inline]

Definition at line 60 of file TargetPhraseCollection.h.

References m_collection.

size_t Moses::TargetPhraseCollection::GetSize (  )  const [inline]

number of target phrases in this collection

Definition at line 66 of file TargetPhraseCollection.h.

References m_collection.

Referenced by Moses::DecodeStepTranslation::Process(), and Moses::DecodeStepTranslation::ProcessInitialTranslation().

Here is the caller graph for this function:

bool Moses::TargetPhraseCollection::IsEmpty (  )  const [inline]

wether collection has any phrases

Definition at line 70 of file TargetPhraseCollection.h.

References m_collection.

Referenced by Moses::ChartTranslationOptionList::Add(), Moses::PDTAimp::CacheSource(), Moses::ChartRuleLookupManagerOnDisk::GetChartRuleCollection(), and Moses::PDTAimp::GetTargetPhraseCollection().

Here is the caller graph for this function:

void Moses::TargetPhraseCollection::NthElement ( size_t  tableLimit  ) 

divide collection into 2 buckets using std::nth_element, the top & bottom according to table limit

Definition at line 36 of file TargetPhraseCollection.cpp.

References m_collection.

Referenced by Moses::PhraseDictionaryDynSuffixArray::GetTargetPhraseCollection(), Prune(), and Moses::PhraseDictionaryNode::Sort().

Here is the caller graph for this function:

void Moses::TargetPhraseCollection::Prune ( bool  adhereTableLimit,
size_t  tableLimit 
)

Definition at line 45 of file TargetPhraseCollection.cpp.

References m_collection, and NthElement().

Referenced by Moses::PhraseDictionaryNodeSCFG::Prune().

Here is the call graph for this function:

Here is the caller graph for this function:

void Moses::TargetPhraseCollection::Sort ( bool  adhereTableLimit,
size_t  tableLimit 
)

Definition at line 58 of file TargetPhraseCollection.cpp.

References m_collection.

Referenced by Moses::PhraseDictionaryNodeSCFG::Sort().

Here is the caller graph for this function:


Member Data Documentation


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

Generated on Wed Feb 8 23:04:10 2012 for Moses by  doxygen 1.5.9