1
/***************************************************************************
4
--------------------------------------------------------------------
5
Copyright : (C) 2007 by Knut Franke, Tilman Benkert
6
Email (use @ for *) : knut.franke*gmx.de, thzs*gmx.net
7
Description : Private data managed by AbstractAspect.
9
***************************************************************************/
11
/***************************************************************************
13
* This program is free software; you can redistribute it and/or modify *
14
* it under the terms of the GNU General Public License as published by *
15
* the Free Software Foundation; either version 2 of the License, or *
16
* (at your option) any later version. *
18
* This program is distributed in the hope that it will be useful, *
19
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
20
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
21
* GNU General Public License for more details. *
23
* You should have received a copy of the GNU General Public License *
24
* along with this program; if not, write to the Free Software *
25
* Foundation, Inc., 51 Franklin Street, Fifth Floor, *
26
* Boston, MA 02110-1301 USA *
28
***************************************************************************/
29
#ifndef ASPECT_PRIVATE_H
30
#define ASPECT_PRIVATE_H
32
#include "AbstractAspect.h"
40
//! Private data managed by AbstractAspect.
41
class AbstractAspect::Private
44
Private(AbstractAspect * owner, const QString &name);
47
void addChild(AbstractAspect* child);
48
void insertChild(int index, AbstractAspect* child);
49
int indexOfChild(const AbstractAspect *child) const;
50
int removeChild(AbstractAspect* child);
51
int childCount() const;
52
AbstractAspect* child(int index);
55
void setName(const QString &value);
56
QString comment() const;
57
void setComment(const QString &value);
58
QString captionSpec() const;
59
void setCaptionSpec(const QString &value);
60
QDateTime creationTime() const;
61
void setCreationTime(const QDateTime& time);
63
QString caption() const;
64
AbstractAspect * owner() { return d_owner; }
65
AbstractAspect * parent() { return d_parent; }
67
QString uniqueNameFor(const QString ¤t_name) const;
69
static QSettings * g_settings;
70
static QHash<QString, QVariant> g_defaults;
73
static int indexOfMatchingBrace(const QString &str, int start);
74
QList< AbstractAspect* > d_children;
75
QString d_name, d_comment, d_caption_spec;
76
QDateTime d_creation_time;
77
AbstractAspect * d_owner;
78
AbstractAspect * d_parent;
81
#endif // ifndef ASPECT_PRIVATE_H