xmlelementcodeblock.h
00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017 #ifndef XMLELEMENTCODEBLOCK_H
00018 #define XMLELEMENTCODEBLOCK_H
00019
00020 #include <qstring.h>
00021
00022 #include "../umlattributelist.h"
00023 #include "../hierarchicalcodeblock.h"
00024
00025 class CodeDocument;
00026 class UMLAttribute;
00027
00028 class XMLElementCodeBlock : public HierarchicalCodeBlock
00029 {
00030 Q_OBJECT
00031 public:
00032
00033
00034
00035
00039 XMLElementCodeBlock ( CodeDocument * parentDoc, const QString & nodeName, const QString & comment = "");
00040
00044 virtual ~XMLElementCodeBlock ( );
00045
00049 virtual void saveToXMI ( QDomDocument & doc, QDomElement & root );
00050
00054 virtual void loadFromXMI ( QDomElement & root );
00055
00056 virtual UMLAttributeList * getAttributeList();
00057
00058 virtual void setNodeName (const QString &name);
00059 virtual QString getNodeName ();
00060
00061 void addAttribute (UMLAttribute * at);
00062
00063 protected:
00064
00068 virtual void setAttributesOnNode ( QDomDocument & doc, QDomElement & blockElement);
00069
00073 virtual void setAttributesFromNode ( QDomElement & element);
00074
00078 void updateContent ( );
00079
00080 private:
00081
00082 UMLAttributeList m_attList;
00083 QString m_nodeName;
00084 void init (CodeDocument * parent, const QString &nodeName, const QString &comment);
00085
00086 };
00087
00088 #endif // XMLELEMENTCODEBLOCK_H
This file is part of the documentation for umbrello Version 3.1.0.