2008-06-11 14:52:57 +04:00
|
|
|
#pragma once
|
|
|
|
|
|
|
|
#include <vector>
|
|
|
|
#include <string>
|
|
|
|
#include "InputType.h"
|
|
|
|
|
2008-10-09 03:51:26 +04:00
|
|
|
namespace Moses
|
|
|
|
{
|
|
|
|
|
2008-06-11 14:52:57 +04:00
|
|
|
/** This struct is used for storing XML force translation data for a given range in the sentence
|
|
|
|
*/
|
|
|
|
struct XmlOption {
|
|
|
|
|
|
|
|
size_t startPos, endPos;
|
|
|
|
std::vector<std::string> targetPhrases;
|
|
|
|
std::vector<float> targetScores;
|
|
|
|
|
|
|
|
XmlOption(int s, int e, std::string targetPhrase, float targetScore): startPos(s), endPos(e) {
|
|
|
|
targetPhrases.push_back(targetPhrase);
|
|
|
|
targetScores.push_back(targetScore);
|
|
|
|
}
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
std::vector<TranslationOption*> ProcessAndStripXMLTags(std::string& line, const InputType &source);
|
|
|
|
|
2008-10-09 03:51:26 +04:00
|
|
|
}
|
|
|
|
|
2008-06-11 14:52:57 +04:00
|
|
|
|