Moses::RuleScope Class Reference

#include <RuleScope.h>

Inheritance diagram for Moses::RuleScope:

Inheritance graph
[legend]
Collaboration diagram for Moses::RuleScope:

Collaboration graph
[legend]

List of all members.

Public Member Functions

 RuleScope (const std::string &line)
virtual bool IsUseable (const FactorMask &mask) const
virtual void EvaluateInIsolation (const Phrase &source, const TargetPhrase &targetPhrase, ScoreComponentCollection &scoreBreakdown, ScoreComponentCollection &estimatedScores) const
virtual void EvaluateWithSourceContext (const InputType &input, const InputPath &inputPath, const TargetPhrase &targetPhrase, const StackVec *stackVec, ScoreComponentCollection &scoreBreakdown, ScoreComponentCollection *estimatedScores=NULL) const
void EvaluateTranslationOptionListWithSourceContext (const InputType &input, const TranslationOptionList &translationOptionList) const
virtual void EvaluateWhenApplied (const Hypothesis &hypo, ScoreComponentCollection *accumulator) const
virtual void EvaluateWhenApplied (const ChartHypothesis &hypo, ScoreComponentCollection *accumulator) const
void SetParameter (const std::string &key, const std::string &value)

Protected Member Functions

bool IsGlueRule (const Phrase &source) const

Protected Attributes

bool m_sourceSyntax
bool m_perScope
bool m_futureCostOnly


Detailed Description

Definition at line 9 of file RuleScope.h.


Constructor & Destructor Documentation

Moses::RuleScope::RuleScope ( const std::string &  line  ) 

Definition at line 9 of file RuleScope.cpp.


Member Function Documentation

void Moses::RuleScope::EvaluateInIsolation ( const Phrase source,
const TargetPhrase targetPhrase,
ScoreComponentCollection scoreBreakdown,
ScoreComponentCollection estimatedScores 
) const [virtual]

void Moses::RuleScope::EvaluateTranslationOptionListWithSourceContext ( const InputType input,
const TranslationOptionList translationOptionList 
) const [inline, virtual]

Implements Moses::FeatureFunction.

Definition at line 31 of file RuleScope.h.

virtual void Moses::RuleScope::EvaluateWhenApplied ( const ChartHypothesis hypo,
ScoreComponentCollection accumulator 
) const [inline, virtual]

Same for chart-based features.

Implements Moses::StatelessFeatureFunction.

Definition at line 40 of file RuleScope.h.

virtual void Moses::RuleScope::EvaluateWhenApplied ( const Hypothesis hypo,
ScoreComponentCollection accumulator 
) const [inline, virtual]

This should be implemented for features that apply to phrase-based models.

Implements Moses::StatelessFeatureFunction.

Definition at line 36 of file RuleScope.h.

virtual void Moses::RuleScope::EvaluateWithSourceContext ( const InputType input,
const InputPath inputPath,
const TargetPhrase targetPhrase,
const StackVec stackVec,
ScoreComponentCollection scoreBreakdown,
ScoreComponentCollection estimatedScores = NULL 
) const [inline, virtual]

Implements Moses::FeatureFunction.

Definition at line 23 of file RuleScope.h.

bool Moses::RuleScope::IsGlueRule ( const Phrase source  )  const [protected]

Definition at line 94 of file RuleScope.cpp.

Referenced by EvaluateInIsolation().

Here is the caller graph for this function:

virtual bool Moses::RuleScope::IsUseable ( const FactorMask mask  )  const [inline, virtual]

Implements Moses::FeatureFunction.

Definition at line 14 of file RuleScope.h.

void Moses::RuleScope::SetParameter ( const std::string &  key,
const std::string &  value 
) [virtual]

Reimplemented from Moses::FeatureFunction.

Definition at line 81 of file RuleScope.cpp.

References m_futureCostOnly, m_perScope, m_sourceSyntax, and Moses::Scan< bool >().

Here is the call graph for this function:


Member Data Documentation

Definition at line 49 of file RuleScope.h.

Referenced by EvaluateInIsolation(), and SetParameter().

bool Moses::RuleScope::m_perScope [protected]

Definition at line 48 of file RuleScope.h.

Referenced by EvaluateInIsolation(), and SetParameter().

Definition at line 47 of file RuleScope.h.

Referenced by SetParameter().


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

Generated on Thu Jul 6 00:33:10 2017 for Moses by  doxygen 1.5.9