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

umloperationdialog.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) 2002-2020 *
8 * Umbrello UML Modeller Authors <umbrello-devel@kde.org> *
9 ***************************************************************************/
10
11 #ifndef UMLOPERATIONDIALOG_H
12 #define UMLOPERATIONDIALOG_H
13
14 //kde includes
15 #include "singlepagedialogbase.h"
16
17 class DocumentationWidget;
18 class KComboBox;
19 class DialogsPopupMenu;
20 class QAbstractButton;
21 class QGroupBox;
22 class QListWidget;
23 class QListWidgetItem;
24 class QLabel;
25 class QRadioButton;
26 class QPushButton;
27 class QCheckBox;
28 class QToolButton;
29 class KLineEdit;
30 class UMLDoc;
31 class UMLOperation;
32 class UMLDatatypeWidget;
33 class UMLStereotypeWidget;
34 class VisibilityEnumWidget;
35
40 class UMLOperationDialog : public SinglePageDialogBase
41 {
42 Q_OBJECT
43 public:
44
45 UMLOperationDialog(QWidget * parent, UMLOperation * pOperation);
46 ~UMLOperationDialog();
47
48 protected:
49
50 void setupDialog();
51
52 bool apply();
53
54 void insertTypesSorted(const QString& type = QString());
55
56 UMLOperation* m_operation;
57 UMLDoc* m_doc;
58 DialogsPopupMenu* m_menu;
59
60 //GUI widgets
61 QGroupBox* m_pParmsGB;
62 QGroupBox* m_pGenGB;
63 QListWidget* m_pParmsLW;
64 QGroupBox* m_pScopeGB;
65 QRadioButton* m_pPublicRB;
66 QRadioButton* m_pPrivateRB;
67 QRadioButton* m_pProtectedRB;
68 QRadioButton* m_pImplementationRB;
69 QLabel* m_pNameL;
70 UMLDatatypeWidget* m_datatypeWidget;
71 UMLStereotypeWidget* m_stereotypeWidget;
72 KLineEdit* m_pNameLE;
73 QCheckBox* m_pAbstractCB;
74 QCheckBox* m_pStaticCB;
75 QCheckBox* m_pQueryCB;
76 QCheckBox* m_virtualCB;
77 QCheckBox* m_inlineCB;
78 QCheckBox* m_pOverrideCB;
79 QPushButton* m_pDeleteButton;
80 QPushButton* m_pPropertiesButton;
81 QToolButton* m_pUpButton;
82 QToolButton* m_pDownButton;
83 DocumentationWidget* m_docWidget;
84 VisibilityEnumWidget* m_visibilityEnumWidget;
85
86 public slots:
87 void slotParmRightButtonPressed(const QPoint &p);
88 void slotParmDoubleClick(QListWidgetItem *item);
89 void slotMenuSelection(QAction* action);
90 void slotNewParameter();
91 void slotDeleteParameter();
92 void slotParameterProperties();
93 void slotParameterUp();
94 void slotParameterDown();
95 void slotParamsBoxClicked(QListWidgetItem* parameterItem);
96 void slotNameChanged(const QString &);
97 };
98
99 #endif
UMLOperationDialog::m_pNameLE
KLineEdit * m_pNameLE
Definition: umloperationdialog.h:72
umlattributelist.h
UMLObject::asUMLClassifier
UMLClassifier * asUMLClassifier()
Definition: umlobject.cpp:1309
template.h
UMLOperation::addParm
void addParm(UMLAttribute *parameter, int position=-1)
Definition: operation.cpp:276
UMLOperationDialog::slotDeleteParameter
void slotDeleteParameter()
Definition: umloperationdialog.cpp:295
UMLOperationDialog::~UMLOperationDialog
~UMLOperationDialog()
Definition: umloperationdialog.cpp:74
UMLOperationDialog::m_pPublicRB
QRadioButton * m_pPublicRB
Definition: umloperationdialog.h:65
UMLClassifier::isInterface
bool isInterface() const
Definition: classifier.cpp:118
ListPopupMenu::mt_Properties
@ mt_Properties
Definition: listpopupmenu.h:182
UMLOperation::setInline
void setInline(bool b)
Definition: operation.cpp:470
UMLAttributeList
Definition: umlattributelist.h:27
UMLObject::name
QString name() const
Definition: umlobject.cpp:211
UMLDatatypeWidget::apply
bool apply()
Definition: umldatatypewidget.cpp:103
stereotype.h
Uml::ID::Reserved
const Type Reserved
special value for illegal ID
Definition: basictypes.h:354
UMLOperation::getParmList
UMLAttributeList getParmList() const
Definition: operation.cpp:178
DialogsPopupMenu
Definition: dialogspopupmenu.h:17
UMLOperationDialog::slotNewParameter
void slotNewParameter()
Definition: umloperationdialog.cpp:268
UMLOperation::moveParmLeft
void moveParmLeft(UMLAttribute *a)
Definition: operation.cpp:106
UMLObject::setStatic
void setStatic(bool bStatic)
Definition: umlobject.cpp:374
UMLOperationDialog::slotParmRightButtonPressed
void slotParmRightButtonPressed(const QPoint &p)
Definition: umloperationdialog.cpp:222
UMLObject::asUMLAttribute
UMLAttribute * asUMLAttribute()
Definition: umlobject.cpp:1305
UMLOperation::removeParm
void removeParm(UMLAttribute *a, bool emitModifiedSignal=true)
Definition: operation.cpp:158
operation.h
UMLOperationDialog::insertTypesSorted
void insertTypesSorted(const QString &type=QString())
UMLOperationDialog::m_pDownButton
QToolButton * m_pDownButton
Definition: umloperationdialog.h:82
UMLObject::setID
virtual void setID(Uml::ID::Type NewID)
Definition: umlobject.cpp:183
umloperationdialog.h
UMLOperationDialog::m_datatypeWidget
UMLDatatypeWidget * m_datatypeWidget
Definition: umloperationdialog.h:70
documentationwidget.h
UMLOperation::moveParmRight
void moveParmRight(UMLAttribute *a)
Definition: operation.cpp:130
UMLOperation::getConst
bool getConst() const
Definition: operation.cpp:430
Uml::SignatureType::SigNoVis
@ SigNoVis
Definition: basictypes.h:165
UMLObject::umlParent
UMLObject * umlParent() const
Definition: umlobject.cpp:671
UMLOperationDialog::m_visibilityEnumWidget
VisibilityEnumWidget * m_visibilityEnumWidget
Definition: umloperationdialog.h:84
UMLObject::setName
virtual void setName(const QString &strName)
Definition: umlobject.cpp:192
UMLObject::umlPackage
UMLPackage * umlPackage() const
Definition: umlobject.cpp:646
UMLObject::isStatic
bool isStatic() const
Definition: umlobject.cpp:366
SinglePageDialogBase
Definition: singlepagedialogbase.h:36
VisibilityEnumWidget
Definition: visibilityenumwidget.h:27
UMLOperationDialog::m_pAbstractCB
QCheckBox * m_pAbstractCB
Definition: umloperationdialog.h:73
UMLClassifier::checkOperationSignature
UMLOperation * checkOperationSignature(const QString &name, UMLAttributeList opParams, UMLOperation *exemptOp=0)
Definition: classifier.cpp:134
umldatatypewidget.h
Dialog_Utils::makeLabeledEditField
KLineEdit * makeLabeledEditField(QGridLayout *layout, int row, QLabel *&label, const QString &labelText, KLineEdit *&editField, const QString &editFieldText, int columnOffset)
Definition: dialog_utils.cpp:52
singlepagedialogbase.h
UMLOperation::getUniqueParameterName
QString getUniqueParameterName()
Definition: operation.cpp:289
UMLOperationDialog::m_pScopeGB
QGroupBox * m_pScopeGB
Definition: umloperationdialog.h:64
UMLObject::isAbstract
bool isAbstract() const
Definition: umlobject.cpp:348
Settings::optionState
OptionState & optionState()
Definition: optionstate.cpp:362
umlclassifierlistitemlist.h
UMLOperationDialog::m_docWidget
DocumentationWidget * m_docWidget
Definition: umloperationdialog.h:83
UMLOperationDialog::m_stereotypeWidget
UMLStereotypeWidget * m_stereotypeWidget
Definition: umloperationdialog.h:71
UMLOperation::setConst
void setConst(bool b)
Definition: operation.cpp:422
ListPopupMenu::getAction
QAction * getAction(MenuType idx)
Definition: listpopupmenu.cpp:527
UMLOperation::findParm
UMLAttribute * findParm(const QString &name)
Definition: operation.cpp:189
classifierlistitem.h
UMLStereotypeWidget::apply
void apply()
Definition: umlstereotypewidget.cpp:48
uniqueid.h
DocumentationWidget::apply
void apply()
Definition: documentationwidget.cpp:70
UMLOperation::getOverride
bool getOverride() const
Definition: operation.cpp:446
UMLOperationDialog::m_pStaticCB
QCheckBox * m_pStaticCB
Definition: umloperationdialog.h:74
DialogsPopupMenu::tt_New_Parameter
@ tt_New_Parameter
Definition: dialogspopupmenu.h:36
ListPopupMenu::MenuType
MenuType
< This type hosts all possible menu entry types
Definition: listpopupmenu.h:44
UMLOperationDialog::m_operation
UMLOperation * m_operation
The operation to represent.
Definition: umloperationdialog.h:56
i18n
#define i18n
Definition: main.cpp:39
UMLOperationDialog::setupDialog
void setupDialog()
Definition: umloperationdialog.cpp:81
UMLOperationDialog::m_pParmsGB
QGroupBox * m_pParmsGB
Definition: umloperationdialog.h:61
uDebug
#define uDebug()
Definition: debug_utils.h:122
UMLOperationDialog::slotParameterUp
void slotParameterUp()
Definition: umloperationdialog.cpp:349
UMLOperationDialog
Definition: umloperationdialog.h:41
visibilityenumwidget.h
UMLOperationDialog::m_pPropertiesButton
QPushButton * m_pPropertiesButton
Definition: umloperationdialog.h:80
ComboBoxWidgetBase::addToLayout
void addToLayout(QGridLayout *layout, int row, int startColumn=0)
Definition: comboboxwidgetbase.cpp:51
MyProject\connect
connect()
Definition: namespaces-multiple.php:5
UMLObject::setAbstract
void setAbstract(bool bAbstract)
Definition: umlobject.cpp:356
UMLOperationDialog::m_pParmsLW
QListWidget * m_pParmsLW
Definition: umloperationdialog.h:63
UMLOperationDialog::m_pQueryCB
QCheckBox * m_pQueryCB
Definition: umloperationdialog.h:75
UMLOperationDialog::m_menu
DialogsPopupMenu * m_menu
Menu used in parameter list box.
Definition: umloperationdialog.h:58
UMLApp::app
static UMLApp * app()
Definition: uml.cpp:278
UMLAttribute::copyInto
virtual void copyInto(UMLObject *lhs) const
Definition: attribute.cpp:236
UMLDatatypeWidget
Definition: umldatatypewidget.h:24
UMLStereotypeWidget
Definition: umlstereotypewidget.h:20
UMLDoc
Definition: umldoc.h:75
UMLAttribute
Sets up attribute information.
Definition: attribute.h:28
UMLOperationDialog::slotParameterProperties
void slotParameterProperties()
Definition: umloperationdialog.cpp:309
UMLDoc::setModified
void setModified(bool modified=true)
Definition: umldoc.cpp:3136
UMLOperationDialog::slotParamsBoxClicked
void slotParamsBoxClicked(QListWidgetItem *parameterItem)
Definition: umloperationdialog.cpp:390
UMLOperationDialog::m_inlineCB
QCheckBox * m_inlineCB
Definition: umloperationdialog.h:77
UMLOperationDialog::apply
bool apply()
Definition: umloperationdialog.cpp:412
UMLOperationDialog::slotNameChanged
void slotNameChanged(const QString &)
Definition: umloperationdialog.cpp:217
UniqueID::gen
Uml::ID::Type gen()
Definition: uniqueid.cpp:26
UMLOperation::setVirtual
void setVirtual(bool b)
Definition: operation.cpp:454
UMLOperationDialog::slotParameterDown
void slotParameterDown()
Definition: umloperationdialog.cpp:368
DialogsPopupMenu::TriggerType
TriggerType
< This type hosts all possible menu types.
Definition: dialogspopupmenu.h:22
ListPopupMenu::mt_Delete
@ mt_Delete
Definition: listpopupmenu.h:186
UMLOperationDialog::slotParmDoubleClick
void slotParmDoubleClick(QListWidgetItem *item)
Definition: umloperationdialog.cpp:244
DialogsPopupMenu::tt_Parameter_Selected
@ tt_Parameter_Selected
Definition: dialogspopupmenu.h:39
classifier.h
DocumentationWidget
Definition: documentationwidget.h:27
UMLOperation
Definition: operation.h:25
parameterpropertiesdialog.h
uml.h
UMLOperationDialog::m_pGenGB
QGroupBox * m_pGenGB
Definition: umloperationdialog.h:62
DialogsPopupMenu::tt_Undefined
@ tt_Undefined
Definition: dialogspopupmenu.h:41
UMLClassifier
Information for a non-graphical Concept/Class.
Definition: classifier.h:40
debug_utils.h
dialogspopupmenu.h
UMLOperation::isInline
bool isInline() const
Definition: operation.cpp:478
UMLOperationDialog::m_pPrivateRB
QRadioButton * m_pPrivateRB
Definition: umloperationdialog.h:66
ListPopupMenu::typeFromAction
static MenuType typeFromAction(QAction *action)
Definition: listpopupmenu.cpp:407
UMLOperationDialog::slotMenuSelection
void slotMenuSelection(QAction *action)
Definition: umloperationdialog.cpp:255
VisibilityEnumWidget::apply
void apply()
Definition: visibilityenumwidget.cpp:78
umlstereotypewidget.h
UMLOperationDialog::m_doc
UMLDoc * m_doc
The UMLDocument where all objects live.
Definition: umloperationdialog.h:57
ListPopupMenu::mt_Rename
@ mt_Rename
Definition: listpopupmenu.h:183
ListPopupMenu::mt_New_Parameter
@ mt_New_Parameter
Definition: listpopupmenu.h:140
UMLAttribute::toString
QString toString(Uml::SignatureType::Enum sig=Uml::SignatureType::NoSig, bool withStereotype=false)
Definition: attribute.cpp:133
UMLAttribute::clone
virtual UMLObject * clone() const
Definition: attribute.cpp:252
UMLOperationDialog::m_pUpButton
QToolButton * m_pUpButton
Definition: umloperationdialog.h:81
dialog_utils.h
UMLOperation::isVirtual
bool isVirtual() const
Definition: operation.cpp:462
UMLOperationDialog::m_pNameL
QLabel * m_pNameL
Definition: umloperationdialog.h:69
UMLOperationDialog::m_virtualCB
QCheckBox * m_virtualCB
Definition: umloperationdialog.h:76
UMLOperationDialog::m_pProtectedRB
QRadioButton * m_pProtectedRB
Definition: umloperationdialog.h:67
UMLOperationDialog::m_pDeleteButton
QPushButton * m_pDeleteButton
Definition: umloperationdialog.h:79
UMLOperation::setOverride
void setOverride(bool b)
Definition: operation.cpp:438
UMLApp::document
UMLDoc * document() const
Definition: uml.cpp:1064
umldoc.h
UMLOperationDialog::UMLOperationDialog
UMLOperationDialog(QWidget *parent, UMLOperation *pOperation)
Definition: umloperationdialog.cpp:60
UMLOperationDialog::m_pImplementationRB
QRadioButton * m_pImplementationRB
Definition: umloperationdialog.h:68
ParameterPropertiesDialog
A properties dialog box for a parameter.
Definition: parameterpropertiesdialog.h:40
UMLOperationDialog::m_pOverrideCB
QCheckBox * m_pOverrideCB
Definition: umloperationdialog.h:78