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

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

- File List
- File Members

codeblockwithcomments.h
Go to the documentation of this file.
1/*
2 SPDX-License-Identifier: GPL-2.0-or-later
3
4 SPDX-FileCopyrightText: 2003 Brian Thomas <thomas@mail630.gsfc.nasa.gov>
5 SPDX-FileCopyrightText: 2004-2021 Umbrello UML Modeller Authors <umbrello-devel@kde.org>
6*/
7
8#ifndef CODEBLOCKWITHCOMMENTS_H
9#define CODEBLOCKWITHCOMMENTS_H
10
11#include "codeblock.h"
12#include "codecomment.h"
13
14
19 class CodeBlockWithComments : public CodeBlock
20{
21 public:
22
23 explicit CodeBlockWithComments (CodeDocument * parent, const QString & body = QString(), const QString & comment = QString());
24
28 virtual ~CodeBlockWithComments ();
29
30 void setComment (CodeComment * object);
31
32 CodeComment * getComment () const;
33
34 virtual QString toString () const;
35
36 void setOverallIndentationLevel (int level);
37
38 virtual void saveToXMI(QXmlStreamWriter& writer);
39
40 virtual void loadFromXMI (QDomElement & root);
41
42 virtual void setAttributesFromObject (TextBlock * obj);
43
44 protected:
45
46 virtual void setAttributesOnNode (QXmlStreamWriter& writer);
47
48 virtual void setAttributesFromNode (QDomElement & element);
49
50 private:
51
52 CodeComment * m_comment;
53
54};
55
56#endif // CODEBLOCKWITHCOMMENTS_H
CodeBlockWithComments
Definition codeblockwithcomments.h:20
CodeBlockWithComments::setAttributesFromNode
virtual void setAttributesFromNode(QDomElement &element)
Definition codeblockwithcomments.cpp:105
CodeBlockWithComments::CodeBlockWithComments
CodeBlockWithComments(CodeDocument *parent, const QString &body=QString(), const QString &comment=QString())
Definition codeblockwithcomments.cpp:22
CodeBlockWithComments::setAttributesFromObject
virtual void setAttributesFromObject(TextBlock *obj)
Definition codeblockwithcomments.cpp:83
CodeBlockWithComments::getComment
CodeComment * getComment() const
Definition codeblockwithcomments.cpp:46
CodeBlockWithComments::setAttributesOnNode
virtual void setAttributesOnNode(QXmlStreamWriter &writer)
Definition codeblockwithcomments.cpp:68
CodeBlockWithComments::setComment
void setComment(CodeComment *object)
Definition codeblockwithcomments.cpp:38
CodeBlockWithComments::~CodeBlockWithComments
virtual ~CodeBlockWithComments()
Definition codeblockwithcomments.cpp:30
CodeBlockWithComments::setOverallIndentationLevel
void setOverallIndentationLevel(int level)
Definition codeblockwithcomments.cpp:163
CodeBlockWithComments::m_comment
CodeComment * m_comment
Definition codeblockwithcomments.h:52
CodeBlockWithComments::saveToXMI
virtual void saveToXMI(QXmlStreamWriter &writer)
Definition codeblockwithcomments.cpp:54
CodeBlockWithComments::loadFromXMI
virtual void loadFromXMI(QDomElement &root)
Definition codeblockwithcomments.cpp:96
CodeBlockWithComments::toString
virtual QString toString() const
Definition codeblockwithcomments.cpp:136
CodeBlock
Definition codeblock.h:17
CodeComment
Definition codecomment.h:20
CodeDocument
Definition codedocument.h:30
TextBlock
Definition textblock.h:23
codeblock.h
codecomment.h