@@ -1,68 +1,68 | |||||
1 | /**************************************************************************** |
|
1 | /**************************************************************************** | |
2 | ** |
|
2 | ** | |
3 | ** Copyright (C) 2008-2009 Nokia Corporation and/or its subsidiary(-ies). |
|
3 | ** Copyright (C) 2008-2009 Nokia Corporation and/or its subsidiary(-ies). | |
4 | ** All rights reserved. |
|
4 | ** All rights reserved. | |
5 | ** Contact: Nokia Corporation (qt-info@nokia.com) |
|
5 | ** Contact: Nokia Corporation (qt-info@nokia.com) | |
6 | ** |
|
6 | ** | |
7 | ** This file is part of the Qt Script Generator project on Qt Labs. |
|
7 | ** This file is part of the Qt Script Generator project on Qt Labs. | |
8 | ** |
|
8 | ** | |
9 | ** $QT_BEGIN_LICENSE:LGPL$ |
|
9 | ** $QT_BEGIN_LICENSE:LGPL$ | |
10 | ** No Commercial Usage |
|
10 | ** No Commercial Usage | |
11 | ** This file contains pre-release code and may not be distributed. |
|
11 | ** This file contains pre-release code and may not be distributed. | |
12 | ** You may use this file in accordance with the terms and conditions |
|
12 | ** You may use this file in accordance with the terms and conditions | |
13 | ** contained in the Technology Preview License Agreement accompanying |
|
13 | ** contained in the Technology Preview License Agreement accompanying | |
14 | ** this package. |
|
14 | ** this package. | |
15 | ** |
|
15 | ** | |
16 | ** GNU Lesser General Public License Usage |
|
16 | ** GNU Lesser General Public License Usage | |
17 | ** Alternatively, this file may be used under the terms of the GNU Lesser |
|
17 | ** Alternatively, this file may be used under the terms of the GNU Lesser | |
18 | ** General Public License version 2.1 as published by the Free Software |
|
18 | ** General Public License version 2.1 as published by the Free Software | |
19 | ** Foundation and appearing in the file LICENSE.LGPL included in the |
|
19 | ** Foundation and appearing in the file LICENSE.LGPL included in the | |
20 | ** packaging of this file. Please review the following information to |
|
20 | ** packaging of this file. Please review the following information to | |
21 | ** ensure the GNU Lesser General Public License version 2.1 requirements |
|
21 | ** ensure the GNU Lesser General Public License version 2.1 requirements | |
22 | ** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. |
|
22 | ** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. | |
23 | ** |
|
23 | ** | |
24 | ** In addition, as a special exception, Nokia gives you certain additional |
|
24 | ** In addition, as a special exception, Nokia gives you certain additional | |
25 | ** rights. These rights are described in the Nokia Qt LGPL Exception |
|
25 | ** rights. These rights are described in the Nokia Qt LGPL Exception | |
26 | ** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. |
|
26 | ** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. | |
27 | ** |
|
27 | ** | |
28 | ** If you have questions regarding the use of this file, please contact |
|
28 | ** If you have questions regarding the use of this file, please contact | |
29 | ** Nokia at qt-info@nokia.com. |
|
29 | ** Nokia at qt-info@nokia.com. | |
30 | ** |
|
30 | ** | |
31 | ** |
|
31 | ** | |
32 | ** |
|
32 | ** | |
33 | ** |
|
33 | ** | |
34 | ** |
|
34 | ** | |
35 | ** |
|
35 | ** | |
36 | ** |
|
36 | ** | |
37 | ** |
|
37 | ** | |
38 | ** $QT_END_LICENSE$ |
|
38 | ** $QT_END_LICENSE$ | |
39 | ** |
|
39 | ** | |
40 | ****************************************************************************/ |
|
40 | ****************************************************************************/ | |
41 |
|
41 | |||
42 | #ifndef SETUPGENERATOR_H |
|
42 | #ifndef SETUPGENERATOR_H | |
43 | #define SETUPGENERATOR_H |
|
43 | #define SETUPGENERATOR_H | |
44 |
|
44 | |||
45 | #include "generator.h" |
|
45 | #include "generator.h" | |
46 | #include "metaqtscript.h" |
|
46 | #include "metaqtscript.h" | |
47 |
|
47 | |||
48 | class SetupGenerator : public Generator |
|
48 | class SetupGenerator : public Generator | |
49 | { |
|
49 | { | |
50 | Q_OBJECT |
|
50 | Q_OBJECT | |
51 |
|
51 | |||
52 | public: |
|
52 | public: | |
53 | virtual void generate(); |
|
53 | virtual void generate(); | |
54 |
|
54 | |||
55 | void addClass(const QString& package, const AbstractMetaClass *cls); |
|
55 | void addClass(const QString& package, const AbstractMetaClass *cls); | |
56 |
|
56 | |||
57 | static void writeInclude(QTextStream &stream, const Include &inc); |
|
57 | static void writeInclude(QTextStream &stream, const Include &inc); | |
58 |
|
58 | |||
59 | static bool isSpecialStreamingOperator(const AbstractMetaFunction *fun); |
|
59 | static bool isSpecialStreamingOperator(const AbstractMetaFunction *fun); | |
60 |
|
60 | |||
61 | private: |
|
61 | private: | |
62 | QStringList writePolymorphicHandler(QTextStream &s, const QString &package, |
|
62 | QStringList writePolymorphicHandler(QTextStream &s, const QString &package, | |
63 | const AbstractMetaClassList &classes); |
|
63 | const AbstractMetaClassList &polyBaseClasses, QList<const AbstractMetaClass*>& allClasses); | |
64 |
|
64 | |||
65 | QHash<QString, QList<const AbstractMetaClass*> > packHash; |
|
65 | QHash<QString, QList<const AbstractMetaClass*> > packHash; | |
66 | }; |
|
66 | }; | |
67 | #endif // SETUPGENERATOR_H |
|
67 | #endif // SETUPGENERATOR_H | |
68 |
|
68 |
General Comments 0
You need to be logged in to leave comments.
Login now