umbrello: umbrello/codegenerators/python/pythonwriter.h Source File

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

- Main Page
- Related Pages
- Modules
- Namespaces
- Classes
- Files

- File List
- File Members

pythonwriter.h
Go to the documentation of this file.
1/*
2 SPDX-License-Identifier: GPL-2.0-or-later
3
4 SPDX-FileCopyrightText: 2002 Vincent Decorges <vincent.decorges@eivd.ch>
5 SPDX-FileCopyrightText: 2003-2021 Umbrello UML Modeller Authors <umbrello-devel@kde.org>
6*/
7
8#ifndef PYTHONWRITER_H
9#define PYTHONWRITER_H
10
11#include "simplecodegenerator.h"
12#include "umlattributelist.h"
13#include "umloperationlist.h"
14
22 class PythonWriter : public SimpleCodeGenerator
23{
24 Q_OBJECT
25public:
26
27 PythonWriter();
28 virtual ~PythonWriter();
29
30 virtual void writeClass(UMLClassifier *c);
31
32 virtual Uml::ProgrammingLanguage::Enum language() const;
33
34 virtual QStringList reservedKeywords() const;
35
36 QStringList defaultDatatypes() const;
37
38private:
39
40 void writeAttributes(UMLAttributeList atList, QTextStream &py);
41
42 void writeOperations(UMLClassifier *c, QTextStream &h);
43 void writeOperations(const QString& classname, UMLOperationList &opList,
44 QTextStream &h, Uml::Visibility::Enum access);
45
46 static bool hasContainer(const QString &string);
47
48 static QString fixTypeName(const QString &string);
49 QString findIncludeFromType(const QString &string);
50
51 bool m_bNeedPass;
52};
53
54#endif //PYTHONWRITER
PythonWriter
Definition: pythonwriter.h:23
PythonWriter::language
virtual Uml::ProgrammingLanguage::Enum language() const
Definition: pythonwriter.cpp:492
PythonWriter::writeAttributes
void writeAttributes(UMLAttributeList atList, QTextStream &py)
Definition: pythonwriter.cpp:313
PythonWriter::findIncludeFromType
QString findIncludeFromType(const QString &string)
Definition: pythonwriter.cpp:478
PythonWriter::m_bNeedPass
bool m_bNeedPass
True as long as no "pass" has been written.
Definition: pythonwriter.h:51
PythonWriter::writeOperations
void writeOperations(UMLClassifier *c, QTextStream &h)
Definition: pythonwriter.cpp:335
PythonWriter::fixTypeName
static QString fixTypeName(const QString &string)
Definition: pythonwriter.cpp:465
PythonWriter::defaultDatatypes
QStringList defaultDatatypes() const
Definition: pythonwriter.cpp:500
PythonWriter::writeClass
virtual void writeClass(UMLClassifier *c)
Definition: pythonwriter.cpp:177
PythonWriter::reservedKeywords
virtual QStringList reservedKeywords() const
Definition: pythonwriter.cpp:521
PythonWriter::PythonWriter
PythonWriter()
Definition: pythonwriter.cpp:165
PythonWriter::~PythonWriter
virtual ~PythonWriter()
Definition: pythonwriter.cpp:169
PythonWriter::hasContainer
static bool hasContainer(const QString &string)
Definition: pythonwriter.cpp:455
SimpleCodeGenerator
Definition: simplecodegenerator.h:30
UMLAttributeList
Definition: umlattributelist.h:21
UMLClassifier
Information for a non-graphical Concept/Class.
Definition: classifier.h:35
Uml::ProgrammingLanguage::Enum
Enum
Definition: basictypes.h:291
Uml::Visibility::Enum
Enum
Definition: basictypes.h:45
simplecodegenerator.h
umlattributelist.h
umloperationlist.h
UMLOperationList
QList< UMLOperation * > UMLOperationList
Definition: umloperationlist.h:14