#ifndef AGDDHASNAMEHH #define AGDDHASNAMEHH namespace agdd { class HasName; } #include #include "agddAttribute.hh" #include "ExpatInterface/Element.h" namespace agdd { class HasName { private: Attribute _name; public: HasName() : _name("name", Attribute::required) { }; void setName(const string & s) { _name.setValue(s); }; const string getName() { return _name.getSetValue(); }; Attribute getNameAtt() { return _name; }; protected: void nameThisElement(xml::Element * elt) { assert(elt); _name.addAttributeTo(elt); }; }; }; #endif