Changeset View
Changeset View
Standalone View
Standalone View
duchain/classdeclaration.h
Show All 20 Lines | |||||
21 | #define CLASSDECLARATION_H | 21 | #define CLASSDECLARATION_H | ||
22 | 22 | | |||
23 | #include <language/duchain/declaration.h> | 23 | #include <language/duchain/declaration.h> | ||
24 | #include <language/duchain/declarationdata.h> | 24 | #include <language/duchain/declarationdata.h> | ||
25 | #include <language/duchain/classmemberdeclarationdata.h> | 25 | #include <language/duchain/classmemberdeclarationdata.h> | ||
26 | #include <language/duchain/classmemberdeclaration.h> | 26 | #include <language/duchain/classmemberdeclaration.h> | ||
27 | #include <language/duchain/types/alltypes.h> | 27 | #include <language/duchain/types/alltypes.h> | ||
28 | 28 | | |||
29 | #include "javaduchainexport.h" | 29 | #include "javaduchain_export.h" | ||
30 | 30 | | |||
31 | namespace KDevelop { | 31 | namespace KDevelop { | ||
32 | class QualifiedIdentifier; | 32 | class QualifiedIdentifier; | ||
33 | class DUContext; | 33 | class DUContext; | ||
34 | class TopDUContext; | 34 | class TopDUContext; | ||
35 | class HashedString; | 35 | class HashedString; | ||
36 | class RangeInRevision; | 36 | class RangeInRevision; | ||
37 | } | 37 | } | ||
Show All 37 Lines | 50 | public: | |||
75 | APPENDED_LIST_FIRST(ClassDeclarationData, BaseClassInstance, baseClasses); | 75 | APPENDED_LIST_FIRST(ClassDeclarationData, BaseClassInstance, baseClasses); | ||
76 | END_APPENDED_LISTS(ClassDeclarationData, baseClasses); | 76 | END_APPENDED_LISTS(ClassDeclarationData, baseClasses); | ||
77 | }; | 77 | }; | ||
78 | 78 | | |||
79 | 79 | | |||
80 | class KDEVJAVADUCHAIN_EXPORT ClassDeclaration : public KDevelop::ClassMemberDeclaration | 80 | class KDEVJAVADUCHAIN_EXPORT ClassDeclaration : public KDevelop::ClassMemberDeclaration | ||
81 | { | 81 | { | ||
82 | public: | 82 | public: | ||
83 | | ||||
83 | ClassDeclaration(const ClassDeclaration& rhs); | 84 | ClassDeclaration(const ClassDeclaration& rhs); | ||
84 | ClassDeclaration(ClassDeclarationData& data); | 85 | ClassDeclaration(ClassDeclarationData& data); | ||
85 | ClassDeclaration(const KDevelop::RangeInRevision& range, KDevelop::DUContext* context); | 86 | ClassDeclaration(const KDevelop::RangeInRevision& range, KDevelop::DUContext* context); | ||
86 | ~ClassDeclaration(); | 87 | ~ClassDeclaration(); | ||
87 | 88 | | |||
89 | enum StorageSpecifier { | ||||
90 | StaticSpecifier = 0x1 /**< indicates static member */, | ||||
91 | AutoSpecifier = 0x2 /**< indicates automatic determination of member access */, | ||||
92 | FriendSpecifier = 0x4 /**< indicates friend member */, | ||||
93 | ExternSpecifier = 0x8 /**< indicates external declaration */, | ||||
94 | RegisterSpecifier = 0x10 /**< indicates register */, | ||||
95 | MutableSpecifier = 0x20 /**< indicates a mutable member */, | ||||
96 | FinalSpecifier = 0x40 /**< indicates a final declaration */, | ||||
97 | NativeSpecifier = 0x80, | ||||
98 | SynchronizedSpecifier = 0x100, | ||||
99 | StrictFPSpecifier = 0x200, | ||||
100 | AbstractSpecifier = 0x400 | ||||
101 | }; | ||||
102 | Q_DECLARE_FLAGS(StorageSpecifiers, StorageSpecifier) | ||||
103 | | ||||
104 | void setStorageSpecifiers(StorageSpecifiers specifiers); | ||||
105 | | ||||
88 | void clearBaseClasses(); | 106 | void clearBaseClasses(); | ||
89 | ///Count of base-classes | 107 | ///Count of base-classes | ||
90 | uint baseClassesSize() const; | 108 | uint baseClassesSize() const; | ||
91 | ///The types this class is based on | 109 | ///The types this class is based on | ||
92 | const BaseClassInstance* baseClasses() const; | 110 | const BaseClassInstance* baseClasses() const; | ||
93 | void addBaseClass(BaseClassInstance klass); | 111 | void addBaseClass(BaseClassInstance klass); | ||
94 | //Replaces the n'th base-class with the given one. The replaced base-class must have existed. | 112 | //Replaces the n'th base-class with the given one. The replaced base-class must have existed. | ||
95 | void replaceBaseClass(uint n, BaseClassInstance klass); | 113 | void replaceBaseClass(uint n, BaseClassInstance klass); | ||
Show All 11 Lines | |||||
107 | 125 | | |||
108 | enum { | 126 | enum { | ||
109 | Identity = 30 | 127 | Identity = 30 | ||
110 | }; | 128 | }; | ||
111 | 129 | | |||
112 | private: | 130 | private: | ||
113 | virtual KDevelop::Declaration* clonePrivate() const; | 131 | virtual KDevelop::Declaration* clonePrivate() const; | ||
114 | DUCHAIN_DECLARE_DATA(ClassDeclaration) | 132 | DUCHAIN_DECLARE_DATA(ClassDeclaration) | ||
133 | | ||||
134 | bool m_isFinal = false; | ||||
135 | bool m_isNative = false; | ||||
136 | bool m_isSynchronized = false; | ||||
137 | bool m_isStrictFP = false; | ||||
138 | bool m_isAbstract = false; | ||||
139 | | ||||
115 | }; | 140 | }; | ||
116 | 141 | | |||
117 | } | 142 | } | ||
118 | 143 | | |||
119 | #endif // FUNCTIONDECLARATION_H | 144 | #endif // FUNCTIONDECLARATION_H | ||
120 | 145 | |