Debian Codegraph @

Source/Config/CBooleanConfigType.h

raw
1 /*
2 * Copyright (C) 2013-2015, 2019 by the Konclude Developer Team.
3 *
4 * This file is part of the reasoning system Konclude.
5 * For details and support, see <http://konclude.com/>.
6 *
7 * Konclude is free software: you can redistribute it and/or modify
8 * it under the terms of version 3 of the GNU Lesser General Public
9 * License (LGPLv3) as published by the Free Software Foundation.
10 *
11 * Konclude is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU (Lesser) General Public License for more details.
15 *
16 * You should have received a copy of the GNU (Lesser) General Public
17 * License along with Konclude. If not, see <http://www.gnu.org/licenses/>.
18 *
19 */
20
21 #ifndef KONCLUDE_CONFIG_CBOOLEANCONFIGTYPE_H
22 #define KONCLUDE_CONFIG_CBOOLEANCONFIGTYPE_H
23
24 // Libraries includes
25 #include <QString>
26 #include <QVariant>
27
28 // Namespace includes
29 #include "CConfigType.h"
30 #include "CConvertStringConfigType.h"
31 #include "CConvertIntegerConfigType.h"
32 #include "CConvertBooleanConfigType.h"
33
34 // Other includes
35
36
37 // Logger includes
38 #include "Logger/CLogger.h"
39
40
41 namespace Konclude {
42
43 namespace Config {
44
45 /*!
46 *
47 * \class CBooleanConfigType
48 * \author Andreas Steigmiller
49 * \version 0.1
50 * \brief TODO
51 *
52 */
53 class CBooleanConfigType : virtual public CConvertBooleanConfigType, virtual public CConvertIntegerConfigType, virtual public CConvertStringConfigType, virtual public CConfigType {
54 // public methods
55 public:
56 //! Constructor
57 CBooleanConfigType(bool value = false);
58
59 //! Destructor
60 virtual ~CBooleanConfigType();
61
62
63 virtual CBooleanConfigType *getTypeCopy();
64
65 virtual bool supportsVariant();
66
67 virtual CBooleanConfigType *setValue(bool value);
68 virtual bool getValue();
69
70 virtual CBooleanConfigType *readFrom(const QVariant &var);
71 virtual QVariant getVariant();
72
73
74 virtual bool readFromString(const QString &string);
75 virtual QString getString();
76
77 virtual bool readFromInteger(qint64 integer);
78 virtual qint64 getInteger();
79
80 virtual bool readFromBoolean(bool boolean);
81 virtual bool getBoolean();
82
83
84 virtual bool equals(CConfigType *dataType);
85
86 // protected methods
87 protected:
88
89 // protected variables
90 protected:
91 bool boolValue;
92
93 // private methods
94 private:
95
96 // private variables
97 private:
98
99 };
100
101 }; // end namespace Config
102
103 }; // end namespace Konclude
104
105 #endif // KONCLUDE_CONFIG_CBOOLEANCONFIGTYPE_H