Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/moses-smt/mosesdecoder.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHieu Hoang <fishandfrolick@gmail.com>2012-06-01 02:32:24 +0400
committerHieu Hoang <fishandfrolick@gmail.com>2012-06-01 02:32:24 +0400
commit417d5ee57ba980b4a88031550163a218bf9c5a1c (patch)
tree29662a0db328b4fc5fa3ece97cb5bbf931d79fee /biconcor/PhrasePair.h
parent48faedb3bdfe1507d19cf2b76fbc81f3be2ff244 (diff)
move biconcor to /
Diffstat (limited to 'biconcor/PhrasePair.h')
-rw-r--r--biconcor/PhrasePair.h49
1 files changed, 49 insertions, 0 deletions
diff --git a/biconcor/PhrasePair.h b/biconcor/PhrasePair.h
new file mode 100644
index 000000000..f8a7881a0
--- /dev/null
+++ b/biconcor/PhrasePair.h
@@ -0,0 +1,49 @@
+#pragma once
+
+#include <iosfwd>
+
+class Alignment;
+class SuffixArray;
+class TargetCorpus;
+
+class PhrasePair
+{
+public:
+ typedef unsigned int INDEX;
+
+private:
+ SuffixArray *m_suffixArray;
+ TargetCorpus *m_targetCorpus;
+ Alignment *m_alignment;
+ INDEX m_sentence_id;
+ char m_target_length;
+ INDEX m_source_position;
+ char m_source_start, m_source_end;
+ char m_target_start, m_target_end;
+ char m_start_null, m_end_null;
+ char m_pre_null, m_post_null;
+
+public:
+ PhrasePair( SuffixArray *sa, TargetCorpus *tc, Alignment *a, INDEX sentence_id, char target_length, INDEX position, char source_start, char source_end, char target_start, char target_end, char start_null, char end_null, char pre_null, char post_null)
+ :m_suffixArray(sa)
+ ,m_targetCorpus(tc)
+ ,m_alignment(a)
+ ,m_sentence_id(sentence_id)
+ ,m_target_length(target_length)
+ ,m_source_position(position)
+ ,m_source_start(source_start)
+ ,m_source_end(source_end)
+ ,m_target_start(target_start)
+ ,m_target_end(target_end)
+ ,m_start_null(start_null)
+ ,m_end_null(end_null)
+ ,m_pre_null(pre_null)
+ ,m_post_null(post_null)
+ {}
+ ~PhrasePair () {}
+
+ void PrintTarget( std::ostream* out ) const;
+ void Print( std::ostream* out, int width ) const;
+ void PrintHTML( std::ostream* out ) const;
+ void PrintClippedHTML( std::ostream* out, int width ) const;
+};