diff options
author | Marcin Junczys-Dowmunt <junczys@amu.edu.pl> | 2015-01-08 17:35:30 +0300 |
---|---|---|
committer | Marcin Junczys-Dowmunt <junczys@amu.edu.pl> | 2015-01-08 17:35:30 +0300 |
commit | 5b71b2c3a924c438c8df6a39c4e28a699d2cc45a (patch) | |
tree | da194b29ac8807d48376a81dbf0256a9fe02d0f8 /moses/TabbedSentence.h | |
parent | 5da4031724763e7b6bbb652775eec71e9874bbbc (diff) |
ThreadLocalFeatureStorage
Diffstat (limited to 'moses/TabbedSentence.h')
-rw-r--r-- | moses/TabbedSentence.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/moses/TabbedSentence.h b/moses/TabbedSentence.h index 626525a1d..90c11cc39 100644 --- a/moses/TabbedSentence.h +++ b/moses/TabbedSentence.h @@ -23,6 +23,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA #include <vector> #include <string> +#include <cstdlib> #include "Sentence.h" namespace Moses @@ -69,6 +70,12 @@ public: const TabbedColumns& GetColumns() const { return m_columns; } + + const std::string& GetColumn(size_t i) const { + UTIL_THROW_IF2(m_columns.size() <= i, + "There is no column with index " << i); + return m_columns[i]; + } private: TabbedColumns m_columns; |