umbrello  2.32.2
Umbrello UML Modeller is a Unified Modelling Language (UML) diagram program based on KDE Technology
ownedhierarchicalcodeblock.h
Go to the documentation of this file.
1 /*
2  SPDX-License-Identifier: GPL-2.0-or-later
3 
4  SPDX-FileCopyrightText: 2003 Brian Thomas <thomas@mail630.gsfc.nasa.gov>
5  SPDX-FileCopyrightText: 2004-2020 Umbrello UML Modeller Authors <umbrello-devel@kde.org>
6 */
7 
8 #ifndef OWNEDHIERARCHICALCODEBLOCK_H
9 #define OWNEDHIERARCHICALCODEBLOCK_H
10 
11 #include "hierarchicalcodeblock.h"
12 
13 class UMLObject;
14 class CodeDocument;
15 
23 {
24  Q_OBJECT
25 public:
26 
31  OwnedHierarchicalCodeBlock (UMLObject * parent, CodeDocument * parentDoc, const QString &start = QString(), const QString &end = QString(), const QString &comment = QString());
32 
36  virtual ~OwnedHierarchicalCodeBlock ();
37 
39 
40  virtual void updateContent () = 0;
41 
42  // these next 2 methods should be supplied by inheriting classes
43 
47  virtual void saveToXMI1(QXmlStreamWriter& writer) = 0;
48 
52  virtual void loadFromXMI1 (QDomElement & root) = 0;
53 
54 protected:
55 
56  virtual void release ();
57 
58  virtual void setAttributesOnNode (QXmlStreamWriter& writer);
59 
60  virtual void setAttributesFromNode (QDomElement & element);
61 
62  virtual void setAttributesFromObject (TextBlock * obj);
63 
64 private:
65 
66 public slots:
67 
68  void syncToParent ();
69 
70 };
71 
72 #endif // OWNEDHIERARCHICALCODEBLOCK_H
umlrole.h
OwnedHierarchicalCodeBlock::setAttributesFromNode
virtual void setAttributesFromNode(QDomElement &element)
Definition: ownedhierarchicalcodeblock.cpp:79
OwnedHierarchicalCodeBlock::release
virtual void release()
Definition: ownedhierarchicalcodeblock.cpp:34
OwnedHierarchicalCodeBlock::saveToXMI1
virtual void saveToXMI1(QXmlStreamWriter &writer)=0
OwnedCodeBlock
Definition: ownedcodeblock.h:23
OwnedHierarchicalCodeBlock::~OwnedHierarchicalCodeBlock
virtual ~OwnedHierarchicalCodeBlock()
Definition: ownedhierarchicalcodeblock.cpp:25
OwnedHierarchicalCodeBlock::syncToParent
void syncToParent()
Definition: ownedhierarchicalcodeblock.cpp:94
HierarchicalCodeBlock::setAttributesOnNode
virtual void setAttributesOnNode(QXmlStreamWriter &writer)
Definition: hierarchicalcodeblock.cpp:250
hierarchicalcodeblock.h
OwnedCodeBlock::setAttributesFromObject
virtual void setAttributesFromObject(TextBlock *obj)
Definition: ownedcodeblock.cpp:71
Uml::RoleType::A
@ A
Definition: basictypes.h:237
ownedhierarchicalcodeblock.h
Uml::ID::toString
QString toString(const ID::Type &id)
Definition: basictypes.cpp:1300
association.h
OwnedHierarchicalCodeBlock::OwnedHierarchicalCodeBlock
OwnedHierarchicalCodeBlock(UMLObject *parent, CodeDocument *parentDoc, const QString &start=QString(), const QString &end=QString(), const QString &comment=QString())
Definition: ownedhierarchicalcodeblock.cpp:19
CodeDocument
Definition: codedocument.h:29
UMLObject
The base class for UML objects.
Definition: umlobject.h:69
UMLRole
Definition: umlrole.h:19
OwnedCodeBlock::getParentObject
UMLObject * getParentObject()
Definition: ownedcodeblock.cpp:63
HierarchicalCodeBlock::release
virtual void release()
Definition: hierarchicalcodeblock.cpp:385
number
it is up to the author donor to decide if he or she is willing to distribute software through any other system and a licensee cannot impose that choice This section is intended to make thoroughly clear what is believed to be a consequence of the rest of this License If the distribution and or use of the Library is restricted in certain countries either by patents or by copyrighted the original copyright holder who places the Library under this License may add an geographical distribution limitation excluding those so that distribution is permitted only in or among countries not thus excluded In such this License incorporates the limitation as if written in the body of this License The Free Software Foundation may publish revised and or new versions of the Library General Public License from time to time Such new versions will be similar in spirit to the present but may differ in detail to address new problems or concerns Each version is given a distinguishing version number If the Library specifies a version number of this License which applies to it and any later you have the option of following the terms and conditions either of that version or of any later version published by the Free Software Foundation If the Library does not specify a license version number
Definition: LGPL-2.0-only.txt:368
UMLObject::asUMLRole
UMLRole * asUMLRole()
Definition: umlobject.cpp:1407
OwnedHierarchicalCodeBlock::loadFromXMI1
virtual void loadFromXMI1(QDomElement &root)=0
OwnedHierarchicalCodeBlock::updateContent
virtual void updateContent()=0
OwnedHierarchicalCodeBlock
Definition: ownedhierarchicalcodeblock.h:22
CodeBlock::contentType
ContentType contentType() const
Definition: codeblock.cpp:50
CodeBlock::AutoGenerated
@ AutoGenerated
the content was generated by code generation itself
Definition: codeblock.h:24
codedocument.h
HierarchicalCodeBlock
Definition: hierarchicalcodeblock.h:20
OwnedCodeBlock::setAttributesFromNode
virtual void setAttributesFromNode(QDomElement &element)
Definition: ownedcodeblock.cpp:105
OwnedHierarchicalCodeBlock::getParentDocument
CodeDocument * getParentDocument()
Definition: ownedhierarchicalcodeblock.cpp:89
OwnedCodeBlock::release
virtual void release()
Definition: ownedcodeblock.cpp:51
TextBlock::getParentDocument
CodeDocument * getParentDocument() const
Definition: textblock.cpp:66
umlobject.h
HierarchicalCodeBlock::setAttributesFromNode
virtual void setAttributesFromNode(QDomElement &element)
Definition: hierarchicalcodeblock.cpp:277
UMLRole::role
Uml::RoleType::Enum role() const
Definition: umlrole.cpp:164
TextBlock
Definition: textblock.h:22
codegenerator.h
HierarchicalCodeBlock::setAttributesFromObject
virtual void setAttributesFromObject(TextBlock *obj)
Definition: hierarchicalcodeblock.cpp:296
umldoc.h
OwnedHierarchicalCodeBlock::setAttributesFromObject
virtual void setAttributesFromObject(TextBlock *obj)
Definition: ownedhierarchicalcodeblock.cpp:43
OwnedHierarchicalCodeBlock::setAttributesOnNode
virtual void setAttributesOnNode(QXmlStreamWriter &writer)
Definition: ownedhierarchicalcodeblock.cpp:53
OwnedCodeBlock::setAttributesOnNode
virtual void setAttributesOnNode(QXmlStreamWriter &writer)
Definition: ownedcodeblock.cpp:80