umbrello: umbrello/codegenerators/php/php5writer.h Source File

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

php5writer.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 Heiko Nardmann <h.nardmann@secunet.de> *
8 * Thorsten Kunz <tk AT bytecrash DOT net> *
9 * copyright (C) 2003-2020 *
10 * Umbrello UML Modeller Authors <umbrello-devel@kde.org> *
11 ***************************************************************************/
12
13 #ifndef PHP5WRITER_H
14 #define PHP5WRITER_H
15
16 #include "simplecodegenerator.h"
17 #include "umlattributelist.h"
18 #include "umloperationlist.h"
19
24 class Php5Writer : public SimpleCodeGenerator
25 {
26 Q_OBJECT
27 public:
28
29 Php5Writer();
30 virtual ~Php5Writer();
31
32 virtual void writeClass(UMLClassifier *c);
33
34 virtual Uml::ProgrammingLanguage::Enum language() const;
35
36 virtual QStringList reservedKeywords() const;
37
38 private:
39 void writeOperations(UMLClassifier *c, QTextStream &php);
40 void writeOperations(const QString &classname, UMLOperationList &opList,
41 QTextStream &php,
42 bool interface = false, bool generateErrorStub = false);
43
44 void writeAttributes(UMLClassifier *c, QTextStream &php);
45 void writeAttributes(UMLAttributeList &atList, QTextStream &php);
46 };
47
48 #endif //PHP5WRITER
49
umlattributelist.h
UMLClassifier::getOpList
UMLOperationList getOpList(bool includeInherited=false, UMLClassifierSet *alreadyTraversed=0)
Definition: classifier.cpp:939
SimpleCodeGenerator::m_indentation
QString m_indentation
Definition: simplecodegenerator.h:76
Uml::ProgrammingLanguage::Enum
Enum
Definition: basictypes.h:271
UMLClassifier::isInterface
bool isInterface() const
Definition: classifier.cpp:118
UMLCanvasObject::getSuperClasses
UMLClassifierList getSuperClasses(bool withRealizations=true)
Definition: umlcanvasobject.cpp:349
UMLAttributeList
Definition: umlattributelist.h:27
UMLObject::name
QString name() const
Definition: umlobject.cpp:211
umloperationlist.h
CodeGenerator::getHeadingFile
virtual QString getHeadingFile(const QString &file)
Definition: codegenerator.cpp:407
UMLOperation::getParmList
UMLAttributeList getParmList() const
Definition: operation.cpp:178
includes
Definition: includes.h:3
CodeGenerator::cleanName
static QString cleanName(const QString &name)
Definition: codegenerator.cpp:549
Php5Writer::writeOperations
void writeOperations(UMLClassifier *c, QTextStream &php)
Definition: php5writer.cpp:3155
operation.h
UMLAttribute::getInitialValue
QString getInitialValue() const
Definition: attribute.cpp:99
UMLClassifierListItem::getTypeName
virtual QString getTypeName() const
Definition: classifierlistitem.cpp:112
Uml::RoleType::A
@ A
Definition: basictypes.h:239
Php5Writer::language
virtual Uml::ProgrammingLanguage::Enum language() const
Definition: php5writer.cpp:3432
CodeGenerator::findObjectsRelated
static void findObjectsRelated(UMLClassifier *c, UMLPackageList &cList)
Definition: codegenerator.cpp:622
association.h
UMLObject::isStatic
bool isStatic() const
Definition: umlobject.cpp:366
UMLClassifierList
QList< UMLClassifier * > UMLClassifierList
Definition: umlclassifierlist.h:17
UMLObject
The base class for UML objects.
Definition: umlobject.h:74
UMLObject::isAbstract
bool isAbstract() const
Definition: umlobject.cpp:348
CodeGenerator::forceDoc
bool forceDoc() const
Definition: codegenerator.cpp:765
CodeGenerator::formatSourceCode
static QString formatSourceCode(const QString &code, const QString &indentation)
Definition: codegenerator.cpp:743
Uml::Visibility::Public
@ Public
Definition: basictypes.h:60
CodeGenerator::showGeneratedFile
void showGeneratedFile(const QString &filename)
UMLObject::visibility
Uml::Visibility::Enum visibility() const
Definition: umlobject.cpp:466
attribute.h
a
QString a
Definition: petalnode.cpp:18
SimpleCodeGenerator::m_endl
QString m_endl
Definition: simplecodegenerator.h:78
Php5Writer::reservedKeywords
virtual QStringList reservedKeywords() const
Definition: php5writer.cpp:3441
Php5Writer::Php5Writer
Php5Writer()
Definition: php5writer.cpp:2984
CodeGenerator::formatDoc
static QString formatDoc(const QString &text, const QString &linePrefix=QLatin1String(" *"), int lineWidth=80)
Definition: codegenerator.cpp:712
uDebug
#define uDebug()
Definition: debug_utils.h:122
SimpleCodeGenerator
Definition: simplecodegenerator.h:34
Uml::RoleType::B
@ B
Definition: basictypes.h:240
UMLObject::doc
QString doc() const
Definition: umlobject.cpp:435
UMLAttribute
Sets up attribute information.
Definition: attribute.h:28
UMLClassifier::getAttributeList
UMLAttributeList getAttributeList() const
Definition: classifier.cpp:436
UMLPackageList
QList< UMLPackage * > UMLPackageList
Definition: umlpackagelist.h:17
UMLCanvasObject::getAggregations
UMLAssociationList getAggregations()
Definition: umlcanvasobject.cpp:412
CodeGenerator::codeGenerated
void codeGenerated(UMLClassifier *concept, bool generated)
classifier.h
uError
#define uError()
Definition: debug_utils.h:123
UMLOperation
Definition: operation.h:25
UMLClassifier
Information for a non-graphical Concept/Class.
Definition: classifier.h:40
debug_utils.h
UMLAssociation
Sets up association information.
Definition: association.h:33
UMLCanvasObject::getRealizations
virtual UMLAssociationList getRealizations()
Definition: umlcanvasobject.cpp:402
UMLCanvasObject::getCompositions
UMLAssociationList getCompositions()
Definition: umlcanvasobject.cpp:422
php5writer.h
simplecodegenerator.h
Uml::Visibility::Private
@ Private
Definition: basictypes.h:61
Php5Writer::writeClass
virtual void writeClass(UMLClassifier *c)
Definition: php5writer.cpp:2996
CodeGenerator::forceSections
bool forceSections() const
Definition: codegenerator.cpp:775
Uml::Visibility::Protected
@ Protected
Definition: basictypes.h:62
UMLOperationList
QList< UMLOperation * > UMLOperationList
Definition: umloperationlist.h:18
Php5Writer::writeAttributes
void writeAttributes(UMLClassifier *c, QTextStream &php)
Definition: php5writer.cpp:3337
reserved_words
static const char * reserved_words[]
Definition: php5writer.cpp:25
UMLAssociationList
QList< UMLAssociation * > UMLAssociationList
Definition: umlassociationlist.h:18
SimpleCodeGenerator::findFileName
QString findFileName(UMLPackage *concept, const QString &ext)
Definition: simplecodegenerator.cpp:91
umldoc.h
Php5Writer::~Php5Writer
virtual ~Php5Writer()
Definition: php5writer.cpp:2988
CodeGenerator::openFile
bool openFile(QFile &file, const QString &name)
Definition: codegenerator.cpp:523
UMLOperation::getSourceCode
QString getSourceCode() const
Definition: operation.cpp:507
Php5Writer
Definition: php5writer.h:25
UMLPackage
Non-graphical information for a Package.
Definition: package.h:33
Uml::ProgrammingLanguage::PHP5
@ PHP5
Definition: basictypes.h:284