Skip to content
Snippets Groups Projects
Commit be086e8f authored by Paweł Kędzia's avatar Paweł Kędzia
Browse files

Wrapper for TokenMetaData

parent 9c865e49
No related merge requests found
#ifndef SWIG_LIBCORPUS2_TOKENMETADATA_I
#define SWIG_LIBCORPUS2_TOKENMETADATA_I
%module libcorpustokenmetadata
%{
#include <libcorpus2/tokenmetadata.h>
%}
%include "std_map.i"
%include "std_string.i"
%include "std_defs.i"
%include "boost_shared_ptr.i"
%feature("notabstract") Corpus2::TokenMetaData;
%template(TokenMetaDataPtr) boost::shared_ptr<Corpus2::TokenMetaData>;
namespace Corpus2 {
class TokenMetaData {
public:
TokenMetaData();
~TokenMetaData();
boost::shared_ptr<TokenMetaData> clone() const;
bool has_attribute(const std::string& name) const;
std::string get_attribute(const std::string& name) const;
void set_attribute(const std::string& name, const std::string& value);
typedef std::map<std::string, std::string> attr_map_t;
const attr_map_t& attributes() const;
};
}
using namespace std;
using namespace Corpus2;
#endif /* SWIG_LIBCORPUS2_TOKENMETADATA_I */
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment