Skip to content
Snippets Groups Projects
Commit 9dcc1f05 authored by ilor's avatar ilor
Browse files

TSet class

parent 29a28efd
Branches
No related merge requests found
......@@ -18,6 +18,7 @@ SET(libwccl_STAT_SRC
values/position.cpp
values/positionref.cpp
values/strset.cpp
values/tset.cpp
values/value.cpp
variables.cpp
)
......
#include <libwccl/values/tset.h>
namespace Wccl {
const char* TSet::type_name = "TSet";
} /* end ns Wccl */
#ifndef LIBWCCL_VALUES_TSET_H
#define LIBWCCL_VALUES_TSET_H
#include <libwccl/values/value.h>
#include <libcorpus2/tag.h>
namespace Wccl {
class TSet : public Value
{
public:
WCCL_VALUE_PREAMBLE;
TSet()
: tag_()
{
}
explicit TSet(Corpus2::Tag tag)
: tag_(tag)
{
}
const Corpus2::Tag& get_tag() const {
return tag_;
}
void set_tag(const Corpus2::Tag& tag) {
tag_ = tag;
}
Corpus2::Tag& tag_ref() {
return tag_;
}
private:
Corpus2::Tag tag_;
};
} /* end ns Wccl */
#endif // LIBWCCL_VALUES_TSET_H
......@@ -6,6 +6,7 @@
#include <libwccl/values/position.h>
#include <libwccl/values/positionref.h>
#include <libwccl/values/strset.h>
#include <libwccl/values/tset.h>
#include <iostream>
#include <map>
#include <string>
......@@ -86,12 +87,13 @@ class Variables : detail::Vmap<Value>
, detail::Vmap<Position>
, detail::Vmap<PositionRef>
, detail::Vmap<StrSet>
, detail::Vmap<TSet>
{
public:
/// Valid value types, should match the inheritance.
/// the type Value must be first, order of other items is not important
typedef boost::mpl::list<Value,
Bool, Position, PositionRef, StrSet> types;
Bool, Position, PositionRef, StrSet, TSet> types;
/// Constructor, creates an empty instance.
Variables();
......
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