From 235cf24518ca40bec59b497a416d9831db12eaa3 Mon Sep 17 00:00:00 2001 From: Benjamin Paassen Date: Thu, 8 Jan 2015 21:30:31 +0100 Subject: further extended example to include annotations (emphasized and strong). The DemoOutput for that is still missing, though. convenience build functions have also been implemented in Document.cpp. --- src/core/model/Domain.hpp | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'src/core/model/Domain.hpp') diff --git a/src/core/model/Domain.hpp b/src/core/model/Domain.hpp index 6a07b32..027cf88 100644 --- a/src/core/model/Domain.hpp +++ b/src/core/model/Domain.hpp @@ -306,8 +306,7 @@ public: */ FieldDescriptor(Manager &mgr, Handle parent, FieldType fieldType = FieldType::TREE, - std::string name = "", - bool optional = false) + std::string name = "", bool optional = false) : Node(mgr, std::move(name), parent), children(this), fieldType(fieldType), @@ -532,6 +531,13 @@ public: * This class has no special properties and is in essence just a Descriptor. */ class AnnotationClass : public Descriptor { +public: + AnnotationClass(Manager &mgr, std::string name, Handle domain, + // TODO: What would be a wise default value for attributes? + Handle attributesDescriptor) + : Descriptor(mgr, std::move(name), domain, attributesDescriptor) + { + } }; /** -- cgit v1.2.3