LLVM: SBType.h Source File
Description: C++ source code API documentation for LLDB.
Keywords: LLDB,C++,doxygen,API,documentation

LLDB API Documentation

- Main Page
- Namespaces
- Classes
- Files

- File List

SBType.h
Go to the documentation of this file.
1 //===-- SBType.h ------------------------------------------------*- C++ -*-===//
2 //
3 // The LLVM Compiler Infrastructure
4 //
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
7 //
8 //===----------------------------------------------------------------------===//
9
10 #ifndef LLDB_SBType_h_
11 #define LLDB_SBType_h_
12
13 #include "lldb/API/SBDefines.h"
14
15 namespace lldb {
16
17 class SBTypeList;
18
19 class LLDB_API SBTypeMember {
20 public:
21 SBTypeMember();
22
23 SBTypeMember(const lldb::SBTypeMember &rhs);
24
25 ~SBTypeMember();
26
27 lldb::SBTypeMember &operator=(const lldb::SBTypeMember &rhs);
28
29 bool IsValid() const;
30
31 const char *GetName();
32
33 lldb::SBType GetType();
34
35 uint64_t GetOffsetInBytes();
36
37 uint64_t GetOffsetInBits();
38
39 bool IsBitfield();
40
41 uint32_t GetBitfieldSizeInBits();
42
43 bool GetDescription(lldb::SBStream &description,
44 lldb::DescriptionLevel description_level);
45
46 protected:
47 friend class SBType;
48
49 void reset(lldb_private::TypeMemberImpl *);
50
51 lldb_private::TypeMemberImpl &ref();
52
53 const lldb_private::TypeMemberImpl &ref() const;
54
55 std::unique_ptr<lldb_private::TypeMemberImpl> m_opaque_ap;
56 };
57
58 class SBTypeMemberFunction {
59 public:
60 SBTypeMemberFunction();
61
62 SBTypeMemberFunction(const lldb::SBTypeMemberFunction &rhs);
63
64 ~SBTypeMemberFunction();
65
66 lldb::SBTypeMemberFunction &operator=(const lldb::SBTypeMemberFunction &rhs);
67
68 bool IsValid() const;
69
70 const char *GetName();
71
72 const char *GetDemangledName();
73
74 const char *GetMangledName();
75
76 lldb::SBType GetType();
77
78 lldb::SBType GetReturnType();
79
80 uint32_t GetNumberOfArguments();
81
82 lldb::SBType GetArgumentTypeAtIndex(uint32_t);
83
84 lldb::MemberFunctionKind GetKind();
85
86 bool GetDescription(lldb::SBStream &description,
87 lldb::DescriptionLevel description_level);
88
89 protected:
90 friend class SBType;
91
92 void reset(lldb_private::TypeMemberFunctionImpl *);
93
94 lldb_private::TypeMemberFunctionImpl &ref();
95
96 const lldb_private::TypeMemberFunctionImpl &ref() const;
97
98 lldb::TypeMemberFunctionImplSP m_opaque_sp;
99 };
100
101 class SBType {
102 public:
103 SBType();
104
105 SBType(const lldb::SBType &rhs);
106
107 ~SBType();
108
109 bool IsValid() const;
110
111 uint64_t GetByteSize();
112
113 bool IsPointerType();
114
115 bool IsReferenceType();
116
117 bool IsFunctionType();
118
119 bool IsPolymorphicClass();
120
121 bool IsArrayType();
122
123 bool IsVectorType();
124
125 bool IsTypedefType();
126
127 bool IsAnonymousType();
128
129 lldb::SBType GetPointerType();
130
131 lldb::SBType GetPointeeType();
132
133 lldb::SBType GetReferenceType();
134
135 lldb::SBType GetTypedefedType();
136
137 lldb::SBType GetDereferencedType();
138
139 lldb::SBType GetUnqualifiedType();
140
141 lldb::SBType GetArrayElementType();
142
143 lldb::SBType GetArrayType(uint64_t size);
144
145 lldb::SBType GetVectorElementType();
146
147 lldb::SBType GetCanonicalType();
148 // Get the "lldb::BasicType" enumeration for a type. If a type is not a basic
149 // type eBasicTypeInvalid will be returned
150 lldb::BasicType GetBasicType();
151
152 // The call below confusing and should really be renamed to "CreateBasicType"
153 lldb::SBType GetBasicType(lldb::BasicType type);
154
155 uint32_t GetNumberOfFields();
156
157 uint32_t GetNumberOfDirectBaseClasses();
158
159 uint32_t GetNumberOfVirtualBaseClasses();
160
161 lldb::SBTypeMember GetFieldAtIndex(uint32_t idx);
162
163 lldb::SBTypeMember GetDirectBaseClassAtIndex(uint32_t idx);
164
165 lldb::SBTypeMember GetVirtualBaseClassAtIndex(uint32_t idx);
166
167 lldb::SBTypeEnumMemberList GetEnumMembers();
168
169 uint32_t GetNumberOfTemplateArguments();
170
171 lldb::SBType GetTemplateArgumentType(uint32_t idx);
172
173 lldb::TemplateArgumentKind GetTemplateArgumentKind(uint32_t idx);
174
175 lldb::SBType GetFunctionReturnType();
176
177 lldb::SBTypeList GetFunctionArgumentTypes();
178
179 uint32_t GetNumberOfMemberFunctions();
180
181 lldb::SBTypeMemberFunction GetMemberFunctionAtIndex(uint32_t idx);
182
183 const char *GetName();
184
185 const char *GetDisplayTypeName();
186
187 lldb::TypeClass GetTypeClass();
188
189 bool IsTypeComplete();
190
191 uint32_t GetTypeFlags();
192
193 bool GetDescription(lldb::SBStream &description,
194 lldb::DescriptionLevel description_level);
195
196 lldb::SBType &operator=(const lldb::SBType &rhs);
197
198 bool operator==(lldb::SBType &rhs);
199
200 bool operator!=(lldb::SBType &rhs);
201
202 protected:
203 lldb_private::TypeImpl &ref();
204
205 const lldb_private::TypeImpl &ref() const;
206
207 lldb::TypeImplSP GetSP();
208
209 void SetSP(const lldb::TypeImplSP &type_impl_sp);
210
211 lldb::TypeImplSP m_opaque_sp;
212
213 friend class SBFunction;
214 friend class SBModule;
215 friend class SBTarget;
216 friend class SBTypeEnumMember;
217 friend class SBTypeEnumMemberList;
218 friend class SBTypeNameSpecifier;
219 friend class SBTypeMember;
220 friend class SBTypeMemberFunction;
221 friend class SBTypeList;
222 friend class SBValue;
223
224 SBType(const lldb_private::CompilerType &);
225 SBType(const lldb::TypeSP &);
226 SBType(const lldb::TypeImplSP &);
227 };
228
229 class SBTypeList {
230 public:
231 SBTypeList();
232
233 SBTypeList(const lldb::SBTypeList &rhs);
234
235 ~SBTypeList();
236
237 lldb::SBTypeList &operator=(const lldb::SBTypeList &rhs);
238
239 bool IsValid();
240
241 void Append(lldb::SBType type);
242
243 lldb::SBType GetTypeAtIndex(uint32_t index);
244
245 uint32_t GetSize();
246
247 private:
248 std::unique_ptr<lldb_private::TypeListImpl> m_opaque_ap;
249 friend class SBModule;
250 friend class SBCompileUnit;
251 };
252
253 } // namespace lldb
254
255 #endif // LLDB_SBType_h_
lldb::SBType::GetArrayType
lldb::SBType GetArrayType(uint64_t size)
lldb::SBType::SBType
SBType()
lldb::SBTypeMemberFunction::operator=
lldb::SBTypeMemberFunction & operator=(const lldb::SBTypeMemberFunction &rhs)
lldb::SBTypeMemberFunction::SBTypeMemberFunction
SBTypeMemberFunction()
lldb::SBType::IsVectorType
bool IsVectorType()
lldb::SBType::GetNumberOfFields
uint32_t GetNumberOfFields()
lldb::SBType::GetFunctionReturnType
lldb::SBType GetFunctionReturnType()
lldb::SBTypeList::operator=
lldb::SBTypeList & operator=(const lldb::SBTypeList &rhs)
lldb::SBTypeEnumMemberList
Definition: SBTypeEnumMember.h:56
lldb::SBTypeList::~SBTypeList
~SBTypeList()
lldb::SBTypeList
class LLDB_API SBTypeList
Definition: SBDefines.h:93
lldb::SBType::IsTypeComplete
bool IsTypeComplete()
lldb::SBType::GetTemplateArgumentKind
lldb::TemplateArgumentKind GetTemplateArgumentKind(uint32_t idx)
lldb::SBType::GetDirectBaseClassAtIndex
lldb::SBTypeMember GetDirectBaseClassAtIndex(uint32_t idx)
lldb::SBTypeMemberFunction::GetReturnType
lldb::SBType GetReturnType()
lldb::SBType::GetByteSize
uint64_t GetByteSize()
lldb::SBType::ref
lldb_private::TypeImpl & ref()
lldb::SBTypeList::SBTypeList
SBTypeList()
lldb::SBType::IsTypedefType
bool IsTypedefType()
lldb::SBTypeMemberFunction::m_opaque_sp
lldb::TypeMemberFunctionImplSP m_opaque_sp
Definition: SBType.h:98
lldb::SBType
Definition: SBType.h:101
lldb::SBTypeMemberFunction::GetMangledName
const char * GetMangledName()
lldb::SBTypeMemberFunction::GetDescription
bool GetDescription(lldb::SBStream &description, lldb::DescriptionLevel description_level)
lldb::SBType::GetNumberOfTemplateArguments
uint32_t GetNumberOfTemplateArguments()
SBDefines.h
lldb::SBType::GetCanonicalType
lldb::SBType GetCanonicalType()
lldb::SBType::GetNumberOfMemberFunctions
uint32_t GetNumberOfMemberFunctions()
lldb::SBTypeMember
Definition: SBType.h:19
lldb::SBTypeMemberFunction::ref
lldb_private::TypeMemberFunctionImpl & ref()
lldb::SBType::GetTypeFlags
uint32_t GetTypeFlags()
lldb::SBTypeMemberFunction::GetKind
lldb::MemberFunctionKind GetKind()
lldb::SBType::~SBType
~SBType()
lldb::SBTypeEnumMember
Definition: SBTypeEnumMember.h:18
lldb::SBType::GetDereferencedType
lldb::SBType GetDereferencedType()
lldb::SBTypeList::IsValid
bool IsValid()
lldb::SBTypeMemberFunction::GetName
const char * GetName()
lldb::SBType::GetTemplateArgumentType
lldb::SBType GetTemplateArgumentType(uint32_t idx)
lldb::SBValue
Definition: SBValue.h:22
lldb::SBTypeList::Append
void Append(lldb::SBType type)
lldb::SBType::GetNumberOfDirectBaseClasses
uint32_t GetNumberOfDirectBaseClasses()
lldb::SBTypeMemberFunction::IsValid
bool IsValid() const
lldb::SBType::operator!=
bool operator!=(lldb::SBType &rhs)
lldb::SBType::IsArrayType
bool IsArrayType()
lldb::SBType::IsFunctionType
bool IsFunctionType()
lldb::SBType::GetBasicType
lldb::BasicType GetBasicType()
lldb::SBType::GetArrayElementType
lldb::SBType GetArrayElementType()
lldb::SBType::IsValid
bool IsValid() const
lldb::SBType::GetUnqualifiedType
lldb::SBType GetUnqualifiedType()
lldb::SBCompileUnit
Definition: SBCompileUnit.h:18
lldb::SBType::GetNumberOfVirtualBaseClasses
uint32_t GetNumberOfVirtualBaseClasses()
lldb::SBType::GetPointerType
lldb::SBType GetPointerType()
lldb::SBTypeMemberFunction::~SBTypeMemberFunction
~SBTypeMemberFunction()
lldb::SBType::IsAnonymousType
bool IsAnonymousType()
lldb::SBType::GetFunctionArgumentTypes
lldb::SBTypeList GetFunctionArgumentTypes()
lldb::SBModule
Definition: SBModule.h:21
lldb::SBType::IsPolymorphicClass
bool IsPolymorphicClass()
lldb::SBType::IsPointerType
bool IsPointerType()
lldb::SBType::GetVirtualBaseClassAtIndex
lldb::SBTypeMember GetVirtualBaseClassAtIndex(uint32_t idx)
lldb::SBType::GetTypedefedType
lldb::SBType GetTypedefedType()
lldb::SBTypeMemberFunction::GetArgumentTypeAtIndex
lldb::SBType GetArgumentTypeAtIndex(uint32_t)
lldb::SBType::GetTypeClass
lldb::TypeClass GetTypeClass()
lldb::SBType::operator=
lldb::SBType & operator=(const lldb::SBType &rhs)
lldb::SBType::GetMemberFunctionAtIndex
lldb::SBTypeMemberFunction GetMemberFunctionAtIndex(uint32_t idx)
lldb::SBTypeNameSpecifier
Definition: SBTypeNameSpecifier.h:18
lldb::SBTypeMemberFunction::GetDemangledName
const char * GetDemangledName()
lldb::SBFunction
Definition: SBFunction.h:19
lldb::SBTypeMemberFunction::GetNumberOfArguments
uint32_t GetNumberOfArguments()
lldb::SBType::IsReferenceType
bool IsReferenceType()
lldb::SBType::GetPointeeType
lldb::SBType GetPointeeType()
lldb::SBType::GetEnumMembers
lldb::SBTypeEnumMemberList GetEnumMembers()
lldb::SBType::SetSP
void SetSP(const lldb::TypeImplSP &type_impl_sp)
lldb::SBTypeList::GetTypeAtIndex
lldb::SBType GetTypeAtIndex(uint32_t index)
lldb::SBType::GetName
const char * GetName()
lldb::SBTypeMember::m_opaque_ap
std::unique_ptr< lldb_private::TypeMemberImpl > m_opaque_ap
Definition: SBType.h:55
lldb::SBType::operator==
bool operator==(lldb::SBType &rhs)
lldb::SBTypeMemberFunction::reset
void reset(lldb_private::TypeMemberFunctionImpl *)
lldb::SBType::GetDescription
bool GetDescription(lldb::SBStream &description, lldb::DescriptionLevel description_level)
lldb::SBTypeMemberFunction
Definition: SBType.h:58
lldb::SBTypeList
Definition: SBType.h:229
lldb::SBStream
Definition: SBStream.h:19
lldb::SBType::GetDisplayTypeName
const char * GetDisplayTypeName()
lldb::SBTypeList::GetSize
uint32_t GetSize()
lldb::SBType::GetVectorElementType
lldb::SBType GetVectorElementType()
lldb::SBTypeMemberFunction::GetType
lldb::SBType GetType()
lldb::SBType::GetFieldAtIndex
lldb::SBTypeMember GetFieldAtIndex(uint32_t idx)
lldb::SBType::m_opaque_sp
lldb::TypeImplSP m_opaque_sp
Definition: SBType.h:211
lldb::SBTarget
Definition: SBTarget.h:34
lldb::SBType::GetSP
lldb::TypeImplSP GetSP()
lldb::SBType::GetReferenceType
lldb::SBType GetReferenceType()