summaryrefslogtreecommitdiff
path: root/decoder/dict.cc
diff options
context:
space:
mode:
authorredpony <redpony@ec762483-ff6d-05da-a07a-a48fb63a330f>2010-06-29 17:21:28 +0000
committerredpony <redpony@ec762483-ff6d-05da-a07a-a48fb63a330f>2010-06-29 17:21:28 +0000
commit1a1f3094010bd85acbfefe64743ebde04f0b41a4 (patch)
tree18a740aac72eee3eef70d3b3788b8bca121424ad /decoder/dict.cc
parent321b5cfe9ce2a84e62cdd185b55cbac5c133b549 (diff)
isolate warning messages
git-svn-id: https://ws10smt.googlecode.com/svn/trunk@56 ec762483-ff6d-05da-a07a-a48fb63a330f
Diffstat (limited to 'decoder/dict.cc')
-rw-r--r--decoder/dict.cc11
1 files changed, 11 insertions, 0 deletions
diff --git a/decoder/dict.cc b/decoder/dict.cc
new file mode 100644
index 00000000..485fa348
--- /dev/null
+++ b/decoder/dict.cc
@@ -0,0 +1,11 @@
+#include "dict.h"
+
+#include <string>
+#include <vector>
+#include <boost/regex.hpp>
+#include <boost/algorithm/string/regex.hpp>
+
+void Dict::AsVector(const WordID& id, std::vector<std::string>* results) const {
+ boost::algorithm::split_regex(*results, Convert(id), boost::regex("\\|\\|\\|"));
+}
+