diff options
author | Ulrich Germann <Ulrich.Germann@gmail.com> | 2015-10-17 18:36:21 +0300 |
---|---|---|
committer | Ulrich Germann <Ulrich.Germann@gmail.com> | 2015-10-17 18:36:21 +0300 |
commit | cdcafd817b10d51ab646d318930f44440cffbf24 (patch) | |
tree | 97a1f49bb43388ef290c2ddc3c3339db173d186c /moses/InputPath.h | |
parent | 2df1301946b37819f21572116ee7901e5ac08d6b (diff) |
InputPath now has a weak pointer to the TranslationTask it belongs to.
Diffstat (limited to 'moses/InputPath.h')
-rw-r--r-- | moses/InputPath.h | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/moses/InputPath.h b/moses/InputPath.h index c67d88795..e8b5978ad 100644 --- a/moses/InputPath.h +++ b/moses/InputPath.h @@ -1,3 +1,4 @@ +// -*- mode: c++; indent-tabs-mode: nil; tab-width:2 -*- #pragma once #include <map> @@ -33,6 +34,8 @@ class InputPath public: typedef std::map<const PhraseDictionary*, std::pair<const TargetPhraseCollection*, const void*> > TargetPhrases; +public: + ttaskwptr const ttask; protected: const InputPath *m_prevPath; Phrase m_phrase; @@ -57,8 +60,13 @@ public: , m_nextNode(NOT_FOUND) { } - InputPath(const Phrase &phrase, const NonTerminalSet &sourceNonTerms, const WordsRange &range, const InputPath *prevNode - ,const ScorePair *inputScore); + InputPath(ttaskwptr const ttask, + Phrase const& phrase, + NonTerminalSet const& sourceNonTerms, + WordsRange const& range, + InputPath const* prevNode, + ScorePair const* inputScore); + ~InputPath(); const Phrase &GetPhrase() const { |