umbrello: umbrello/uml1model/enumliteral.h Source File

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

enumliteral.h
Go to the documentation of this file.
1 /***************************************************************************
2 * This program is free software; you can redistribute it and/or modify *
3 * it under the terms of the GNU General Public License as published by *
4 * the Free Software Foundation; either version 2 of the License, or *
5 * (at your option) any later version. *
6 * *
7 * copyright (C) 2003-2020 *
8 * Umbrello UML Modeller Authors <umbrello-devel@kde.org> *
9 ***************************************************************************/
10
11 #ifndef ENUMLITERAL_H
12 #define ENUMLITERAL_H
13
14 #include "classifierlistitem.h"
15
25 class UMLEnumLiteral : public UMLClassifierListItem
26 {
27 public:
28 UMLEnumLiteral(UMLObject* parent,
29 const QString& name, Uml::ID::Type id = Uml::ID::None,
30 const QString& v = QString());
31 explicit UMLEnumLiteral(UMLObject* parent);
32
33 bool operator==(const UMLEnumLiteral &rhs) const;
34
35 virtual void copyInto(UMLObject *lhs) const;
36
37 virtual UMLObject* clone() const;
38
39 virtual ~UMLEnumLiteral();
40
41 QString value() const;
42 void setValue(const QString &v);
43
44 QString toString(Uml::SignatureType::Enum sig = Uml::SignatureType::NoSig, bool withStereotype=false);
45
46 virtual void saveToXMI1(QXmlStreamWriter& writer);
47
48 virtual bool showPropertiesDialog(QWidget* parent = 0);
49
50 protected:
51 bool load1(QDomElement& element);
52
59 QString m_Value;
60
61 };
62
63 #endif
UMLClassifierListItem
A base class for classifier list items (e.g. attributes)
Definition: classifierlistitem.h:30
UMLEnumLiteral
Sets up attribute information.
Definition: enumliteral.h:26
UMLEnumLiteral::clone
virtual UMLObject * clone() const
Definition: enumliteral.cpp:120
UMLEnumLiteral::setValue
void setValue(const QString &v)
Definition: enumliteral.cpp:65
UMLEnumLiteral::operator==
bool operator==(const UMLEnumLiteral &rhs) const
Definition: enumliteral.cpp:94
UMLEnumLiteral::copyInto
virtual void copyInto(UMLObject *lhs) const
Definition: enumliteral.cpp:109
UMLEnumLiteral::saveToXMI1
virtual void saveToXMI1(QXmlStreamWriter &writer)
Definition: enumliteral.cpp:131
UMLEnumLiteral::UMLEnumLiteral
UMLEnumLiteral(UMLObject *parent, const QString &name, Uml::ID::Type id=Uml::ID::None, const QString &v=QString())
Definition: enumliteral.cpp:24
UMLEnumLiteral::~UMLEnumLiteral
virtual ~UMLEnumLiteral()
Definition: enumliteral.cpp:46
UMLEnumLiteral::toString
QString toString(Uml::SignatureType::Enum sig=Uml::SignatureType::NoSig, bool withStereotype=false)
Definition: enumliteral.cpp:79
UMLEnumLiteral::value
QString value() const
Definition: enumliteral.cpp:55
UMLEnumLiteral::load1
bool load1(QDomElement &element)
Definition: enumliteral.cpp:142
UMLEnumLiteral::m_Value
QString m_Value
Definition: enumliteral.h:59
UMLEnumLiteral::showPropertiesDialog
virtual bool showPropertiesDialog(QWidget *parent=0)
Definition: enumliteral.cpp:151
UMLObject
The base class for UML objects.
Definition: umlobject.h:75
UMLObject::name
QString name() const
Definition: umlobject.cpp:211
classifierlistitem.h
v
std::vector< std::string > v
Definition: cxx11-initializer-lists.h:19
Uml::ID::None
const Type None
special value for uninitialized ID
Definition: basictypes.h:387
Uml::ID::Type
std::string Type
Definition: basictypes.h:385
Uml::SignatureType::Enum
Enum
Definition: basictypes.h:174
Uml::SignatureType::NoSig
@ NoSig
Definition: basictypes.h:175