Moses::LexicalReorderingState Class Reference

Abstract class for lexical reordering model states. More...

#include <LexicalReorderingState.h>

Inheritance diagram for Moses::LexicalReorderingState:

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

Collaboration graph
[legend]

List of all members.

Public Member Functions

virtual int Compare (const FFState &o) const =0
virtual LexicalReorderingStateExpand (const TranslationOption &hypo, Scores &scores) const =0

Static Public Member Functions

static LexicalReorderingStateCreateLexicalReorderingState (const std::vector< std::string > &config, LexicalReorderingConfiguration::Direction dir, const InputType &input)

Protected Types

typedef int ReorderingType

Protected Member Functions

 LexicalReorderingState (const LexicalReorderingState *prev, const TranslationOption &topt)
 LexicalReorderingState (const LexicalReorderingConfiguration &config, LexicalReorderingConfiguration::Direction dir, size_t offset)
void CopyScores (Scores &scores, const TranslationOption &topt, ReorderingType reoType) const
void ClearScores (Scores &scores) const
int ComparePrevScores (const Scores *other) const

Protected Attributes

const
LexicalReorderingConfiguration
m_configuration
LexicalReorderingConfiguration::Direction m_direction
size_t m_offset
const Scoresm_prevScore

Static Protected Attributes

static const ReorderingType M = 0
static const ReorderingType NM = 1
static const ReorderingType S = 1
static const ReorderingType D = 2
static const ReorderingType DL = 2
static const ReorderingType DR = 3
static const ReorderingType R = 0
static const ReorderingType L = 1


Detailed Description

Abstract class for lexical reordering model states.

Definition at line 85 of file LexicalReorderingState.h.


Member Typedef Documentation

Definition at line 95 of file LexicalReorderingState.h.


Constructor & Destructor Documentation

Moses::LexicalReorderingState::LexicalReorderingState ( const LexicalReorderingState prev,
const TranslationOption topt 
) [inline, protected]

Definition at line 104 of file LexicalReorderingState.h.

Moses::LexicalReorderingState::LexicalReorderingState ( const LexicalReorderingConfiguration config,
LexicalReorderingConfiguration::Direction  dir,
size_t  offset 
) [inline, protected]

Definition at line 108 of file LexicalReorderingState.h.


Member Function Documentation

void Moses::LexicalReorderingState::ClearScores ( Scores scores  )  const [protected]

virtual int Moses::LexicalReorderingState::Compare ( const FFState o  )  const [pure virtual]

int Moses::LexicalReorderingState::ComparePrevScores ( const Scores other  )  const [protected]

Definition at line 154 of file LexicalReorderingState.cpp.

References Moses::LexicalReorderingConfiguration::GetNumberOfTypes(), m_configuration, m_offset, m_prevScore, and NULL.

Referenced by Moses::HierarchicalReorderingForwardState::Compare(), and Moses::PhraseBasedReorderingState::Compare().

Here is the call graph for this function:

Here is the caller graph for this function:

void Moses::LexicalReorderingState::CopyScores ( Scores scores,
const TranslationOption topt,
ReorderingType  reoType 
) const [protected]

static LexicalReorderingState* Moses::LexicalReorderingState::CreateLexicalReorderingState ( const std::vector< std::string > &  config,
LexicalReorderingConfiguration::Direction  dir,
const InputType input 
) [static]

virtual LexicalReorderingState* Moses::LexicalReorderingState::Expand ( const TranslationOption hypo,
Scores scores 
) const [pure virtual]


Member Data Documentation

const ReorderingType Moses::LexicalReorderingState::D = 2 [static, protected]

const ReorderingType Moses::LexicalReorderingState::DL = 2 [static, protected]

const ReorderingType Moses::LexicalReorderingState::DR = 3 [static, protected]

const ReorderingType Moses::LexicalReorderingState::L = 1 [static, protected]

const ReorderingType Moses::LexicalReorderingState::M = 0 [static, protected]

const ReorderingType Moses::LexicalReorderingState::NM = 1 [static, protected]

const ReorderingType Moses::LexicalReorderingState::R = 0 [static, protected]

const ReorderingType Moses::LexicalReorderingState::S = 1 [static, protected]


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

Generated on Thu Jun 4 00:32:15 2015 for Moses by  doxygen 1.5.9