umbrello: umbrello/uml1model/instanceattribute.h Source File

umbrello 2.32.1 Umbrello UML Modeller is a Unified Modelling Language (UML) diagram program based on KDE Technology

instanceattribute.h
Go to the documentation of this file.
1 /*
2 SPDX-License-Identifier: GPL-2.0-or-later
3 SPDX-FileCopyrightText: 2016-2021 Umbrello UML Modeller Authors <umbrello-devel@kde.org>
4 */
5
6 #ifndef UMLINSTANCEATTRIBUTE_H
7 #define UMLINSTANCEATTRIBUTE_H
8
9 #include "umlobject.h"
10
11 class UMLInstance;
12 class UMLAttribute;
13
33 class UMLInstanceAttribute : public UMLObject
34 {
35 Q_OBJECT
36 public:
37 UMLInstanceAttribute(UMLInstance *parent,
38 UMLAttribute *umlAttr, const QString& value = QString());
39
40 void setAttribute(UMLAttribute *umlAttr);
41 UMLAttribute *getAttribute() const;
42
43 void setValue(const QString& value);
44 QString getValue() const;
45
46 QString toString();
47
48 virtual void saveToXMI1(QXmlStreamWriter& writer);
49
50 virtual bool showPropertiesDialog(QWidget* parent = 0);
51
52 protected:
53 virtual bool load1(QDomElement &element);
54
55 private:
56 void init();
57 QString m_value;
58 };
59
60 #endif // UMLINSTANCEATTRIBUTE_H
UMLAttribute
Sets up attribute information.
Definition: attribute.h:23
UMLInstanceAttribute
Sets up instanceattribute information.
Definition: instanceattribute.h:34
UMLInstanceAttribute::setAttribute
void setAttribute(UMLAttribute *umlAttr)
Definition: instanceattribute.cpp:57
UMLInstanceAttribute::showPropertiesDialog
virtual bool showPropertiesDialog(QWidget *parent=0)
Definition: instanceattribute.cpp:143
UMLInstanceAttribute::setValue
void setValue(const QString &value)
Definition: instanceattribute.cpp:78
UMLInstanceAttribute::init
void init()
UMLInstanceAttribute::init Initialize members of this class.
Definition: instanceattribute.cpp:48
UMLInstanceAttribute::getValue
QString getValue() const
Definition: instanceattribute.cpp:87
UMLInstanceAttribute::getAttribute
UMLAttribute * getAttribute() const
Definition: instanceattribute.cpp:67
UMLInstanceAttribute::m_value
QString m_value
Definition: instanceattribute.h:57
UMLInstanceAttribute::UMLInstanceAttribute
UMLInstanceAttribute(UMLInstance *parent, UMLAttribute *umlAttr, const QString &value=QString())
Definition: instanceattribute.cpp:34
UMLInstanceAttribute::load1
virtual bool load1(QDomElement &element)
Definition: instanceattribute.cpp:118
UMLInstanceAttribute::saveToXMI1
virtual void saveToXMI1(QXmlStreamWriter &writer)
Definition: instanceattribute.cpp:105
UMLInstanceAttribute::toString
QString toString()
Definition: instanceattribute.cpp:96
UMLInstance
Non-graphical Information for an Instance.
Definition: instance.h:43
UMLObject
The base class for UML objects.
Definition: umlobject.h:70
umlobject.h