diff --git a/swig/corpus2.i b/swig/corpus2.i index 7f8a53840b4c75f859f627d8ee72a1f6644a6e46..b925343a152e6c2e05c8aac41b7588b225e4c181 100644 --- a/swig/corpus2.i +++ b/swig/corpus2.i @@ -16,6 +16,7 @@ %include "lexeme.i" %include "libpwrnlperror.i" %include "relation.i" +%include "relationreader.i" %include "sentence.i" %include "tag.i" %include "tagging.i" diff --git a/swig/relationreader.i b/swig/relationreader.i new file mode 100644 index 0000000000000000000000000000000000000000..0fbd550bee2608bf50123dc09bb67be89472a0d1 --- /dev/null +++ b/swig/relationreader.i @@ -0,0 +1,20 @@ +#ifndef SWIG_LIBCORPUS2_RELATIONREADER_I +#define SWIG_LIBCORPUS2_RELATIONREADER_I + +%module libcorpusrelationreader +%{ + #include <libcorpus2/io/relreader.h> +%} + +namespace Corpus2 { + class RelationReader { + public: + RelationReader(const std::string &rela_path); + const std::vector< boost::shared_ptr<Relation> >& relations(); + }; +} + +using namespace std; +using namespace Corpus2; + +#endif /* SWIG_LIBCORPUS2_RELATIONREADER_I */