summaryrefslogtreecommitdiffstats
path: root/src/uml/qumlbehaviorexecutionspecification.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/uml/qumlbehaviorexecutionspecification.cpp')
-rw-r--r--src/uml/qumlbehaviorexecutionspecification.cpp22
1 files changed, 8 insertions, 14 deletions
diff --git a/src/uml/qumlbehaviorexecutionspecification.cpp b/src/uml/qumlbehaviorexecutionspecification.cpp
index 282c3745..f2c38b95 100644
--- a/src/uml/qumlbehaviorexecutionspecification.cpp
+++ b/src/uml/qumlbehaviorexecutionspecification.cpp
@@ -77,6 +77,14 @@ QUmlBehaviorExecutionSpecification::QUmlBehaviorExecutionSpecification(bool crea
}
/*!
+ Destroys the QUmlBehaviorExecutionSpecification.
+ */
+QUmlBehaviorExecutionSpecification::~QUmlBehaviorExecutionSpecification()
+{
+ QModelingElement::deleteQModelingObject();
+}
+
+/*!
Returns a deep-copied clone of the QUmlBehaviorExecutionSpecification.
*/
QModelingElement *QUmlBehaviorExecutionSpecification::clone() const
@@ -84,26 +92,12 @@ QModelingElement *QUmlBehaviorExecutionSpecification::clone() const
QUmlBehaviorExecutionSpecification *c = new QUmlBehaviorExecutionSpecification;
foreach (QUmlComment *element, ownedComments())
c->addOwnedComment(dynamic_cast<QUmlComment *>(element->clone()));
- foreach (QUmlDependency *element, clientDependencies())
- c->addClientDependency(dynamic_cast<QUmlDependency *>(element->clone()));
c->setName(name());
if (nameExpression())
c->setNameExpression(dynamic_cast<QUmlStringExpression *>(nameExpression()->clone()));
c->setVisibility(visibility());
- foreach (QUmlLifeline *element, covered())
- c->addCovered(dynamic_cast<QUmlLifeline *>(element->clone()));
- if (enclosingInteraction())
- c->setEnclosingInteraction(dynamic_cast<QUmlInteraction *>(enclosingInteraction()->clone()));
- if (enclosingOperand())
- c->setEnclosingOperand(dynamic_cast<QUmlInteractionOperand *>(enclosingOperand()->clone()));
foreach (QUmlGeneralOrdering *element, generalOrderings())
c->addGeneralOrdering(dynamic_cast<QUmlGeneralOrdering *>(element->clone()));
- if (finish())
- c->setFinish(dynamic_cast<QUmlOccurrenceSpecification *>(finish()->clone()));
- if (start())
- c->setStart(dynamic_cast<QUmlOccurrenceSpecification *>(start()->clone()));
- if (behavior())
- c->setBehavior(dynamic_cast<QUmlBehavior *>(behavior()->clone()));
return c;
}