IOWrapper Class Reference

#include <IOWrapper.h>

Collaboration diagram for IOWrapper:

Collaboration graph
[legend]

List of all members.

Public Member Functions

 IOWrapper (const std::vector< Moses::FactorType > &inputFactorOrder, const std::vector< Moses::FactorType > &outputFactorOrder, const Moses::FactorMask &inputFactorUsed, size_t nBestSize, const std::string &nBestFilePath)
 IOWrapper (const std::vector< Moses::FactorType > &inputFactorOrder, const std::vector< Moses::FactorType > &outputFactorOrder, const Moses::FactorMask &inputFactorUsed, size_t nBestSize, const std::string &nBestFilePath, const std::string &infilePath)
 ~IOWrapper ()
Moses::InputTypeGetInput (Moses::InputType *inputType)
void OutputBestHypo (const Moses::Hypothesis *hypo, long translationId, bool reportSegmentation, bool reportAllFactors)
void OutputLatticeMBRNBestList (const std::vector< LatticeMBRSolution > &solutions, long translationId)
void Backtrack (const Moses::Hypothesis *hypo)
void ResetTranslationId ()
std::ofstream * GetAlignmentOutputStream ()
std::ostream & GetOutputWordGraphStream ()
std::ostream & GetOutputSearchGraphStream ()
std::ostream & GetDetailedTranslationReportingStream ()

Protected Member Functions

void Initialization (const std::vector< Moses::FactorType > &inputFactorOrder, const std::vector< Moses::FactorType > &outputFactorOrder, const Moses::FactorMask &inputFactorUsed, size_t nBestSize, const std::string &nBestFilePath)

Protected Attributes

long m_translationId
const std::vector
< Moses::FactorType > & 
m_inputFactorOrder
const std::vector
< Moses::FactorType > & 
m_outputFactorOrder
const Moses::FactorMaskm_inputFactorUsed
std::string m_inputFilePath
Moses::InputFileStreamm_inputFile
std::istream * m_inputStream
std::ostream * m_nBestStream
std::ostream * m_outputWordGraphStream
std::ostream * m_outputSearchGraphStream
std::ostream * m_detailedTranslationReportingStream
std::ofstream * m_alignmentOutputStream
bool m_surpressSingleBestOutput


Detailed Description

Definition at line 55 of file IOWrapper.h.


Constructor & Destructor Documentation

IOWrapper::IOWrapper ( const std::vector< Moses::FactorType > &  inputFactorOrder,
const std::vector< Moses::FactorType > &  outputFactorOrder,
const Moses::FactorMask inputFactorUsed,
size_t  nBestSize,
const std::string &  nBestFilePath 
)

IOWrapper::IOWrapper ( const std::vector< Moses::FactorType > &  inputFactorOrder,
const std::vector< Moses::FactorType > &  outputFactorOrder,
const Moses::FactorMask inputFactorUsed,
size_t  nBestSize,
const std::string &  nBestFilePath,
const std::string &  infilePath 
)

IOWrapper::~IOWrapper (  ) 


Member Function Documentation

void IOWrapper::Backtrack ( const Moses::Hypothesis hypo  ) 

Definition at line 300 of file IOWrapper.cpp.

References Moses::Hypothesis::GetId(), Moses::Hypothesis::GetPrevHypo(), NULL, and VERBOSE.

Referenced by OutputBestHypo().

Here is the call graph for this function:

Here is the caller graph for this function:

std::ofstream* IOWrapper::GetAlignmentOutputStream (  )  [inline]

Definition at line 103 of file IOWrapper.h.

References m_alignmentOutputStream.

Referenced by main().

Here is the caller graph for this function:

std::ostream& IOWrapper::GetDetailedTranslationReportingStream (  )  [inline]

Definition at line 114 of file IOWrapper.h.

References m_detailedTranslationReportingStream.

Referenced by main().

Here is the caller graph for this function:

InputType * IOWrapper::GetInput ( Moses::InputType inputType  ) 

Definition at line 172 of file IOWrapper.cpp.

References Moses::InputType::GetTranslationId(), m_inputFactorOrder, m_inputStream, m_translationId, NULL, Moses::InputType::Read(), and Moses::InputType::SetTranslationId().

Referenced by ReadInput().

Here is the call graph for this function:

Here is the caller graph for this function:

std::ostream& IOWrapper::GetOutputSearchGraphStream (  )  [inline]

Definition at line 110 of file IOWrapper.h.

References m_outputSearchGraphStream.

Referenced by main().

Here is the caller graph for this function:

std::ostream& IOWrapper::GetOutputWordGraphStream (  )  [inline]

Definition at line 107 of file IOWrapper.h.

References m_outputWordGraphStream.

Referenced by main().

Here is the caller graph for this function:

void IOWrapper::Initialization ( const std::vector< Moses::FactorType > &  inputFactorOrder,
const std::vector< Moses::FactorType > &  outputFactorOrder,
const Moses::FactorMask inputFactorUsed,
size_t  nBestSize,
const std::string &  nBestFilePath 
) [protected]

void IOWrapper::OutputBestHypo ( const Moses::Hypothesis hypo,
long  translationId,
bool  reportSegmentation,
bool  reportAllFactors 
)

Definition at line 338 of file IOWrapper.cpp.

References Backtrack(), m_outputFactorOrder, m_surpressSingleBestOutput, NULL, OutputInput(), OutputSurface(), and VERBOSE.

Here is the call graph for this function:

void IOWrapper::OutputLatticeMBRNBestList ( const std::vector< LatticeMBRSolution > &  solutions,
long  translationId 
)

void IOWrapper::ResetTranslationId (  )  [inline]

Definition at line 99 of file IOWrapper.h.

References m_translationId.

Referenced by GetIODevice().

Here is the caller graph for this function:


Member Data Documentation

std::ofstream* IOWrapper::m_alignmentOutputStream [protected]

Definition at line 69 of file IOWrapper.h.

Referenced by GetAlignmentOutputStream(), and ~IOWrapper().

Definition at line 68 of file IOWrapper.h.

Referenced by GetDetailedTranslationReportingStream(), and ~IOWrapper().

const std::vector<Moses::FactorType>& IOWrapper::m_inputFactorOrder [protected]

Definition at line 60 of file IOWrapper.h.

Referenced by GetInput().

Definition at line 62 of file IOWrapper.h.

Definition at line 64 of file IOWrapper.h.

Referenced by ~IOWrapper().

std::string IOWrapper::m_inputFilePath [protected]

Definition at line 63 of file IOWrapper.h.

std::istream* IOWrapper::m_inputStream [protected]

Definition at line 65 of file IOWrapper.h.

Referenced by GetInput().

std::ostream* IOWrapper::m_nBestStream [protected]

Definition at line 67 of file IOWrapper.h.

Referenced by ~IOWrapper().

const std::vector<Moses::FactorType>& IOWrapper::m_outputFactorOrder [protected]

Definition at line 61 of file IOWrapper.h.

Referenced by OutputBestHypo().

std::ostream * IOWrapper::m_outputSearchGraphStream [protected]

Definition at line 67 of file IOWrapper.h.

Referenced by GetOutputSearchGraphStream(), and ~IOWrapper().

std::ostream * IOWrapper::m_outputWordGraphStream [protected]

Definition at line 67 of file IOWrapper.h.

Referenced by GetOutputWordGraphStream(), and ~IOWrapper().

Definition at line 70 of file IOWrapper.h.

Referenced by OutputBestHypo(), and ~IOWrapper().

long IOWrapper::m_translationId [protected]

Definition at line 58 of file IOWrapper.h.

Referenced by GetInput(), and ResetTranslationId().


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

Generated on Wed Feb 8 07:04:09 2012 for Moses by  doxygen 1.5.9