LLDB API Documentation

- Main Page
- Namespaces
- Classes
- Files

- File List

SBTypeSummary.h
Go to the documentation of this file.
1 //===-- SBTypeSummary.h -------------------------------------------*- C++
2 //-*-===//
3 //
4 // The LLVM Compiler Infrastructure
5 //
6 // This file is distributed under the University of Illinois Open Source
7 // License. See LICENSE.TXT for details.
8 //
9 //===----------------------------------------------------------------------===//
10
11 #ifndef LLDB_SBTypeSummary_h_
12 #define LLDB_SBTypeSummary_h_
13
14 #include "lldb/API/SBDefines.h"
15
16 namespace lldb {
17 class LLDB_API SBTypeSummaryOptions {
18 public:
19 SBTypeSummaryOptions();
20
21 SBTypeSummaryOptions(const lldb::SBTypeSummaryOptions &rhs);
22
23 SBTypeSummaryOptions(const lldb_private::TypeSummaryOptions *lldb_object_ptr);
24
25 ~SBTypeSummaryOptions();
26
27 bool IsValid();
28
29 lldb::LanguageType GetLanguage();
30
31 lldb::TypeSummaryCapping GetCapping();
32
33 void SetLanguage(lldb::LanguageType);
34
35 void SetCapping(lldb::TypeSummaryCapping);
36
37 protected:
38 friend class SBValue;
39
40 lldb_private::TypeSummaryOptions *operator->();
41
42 const lldb_private::TypeSummaryOptions *operator->() const;
43
44 lldb_private::TypeSummaryOptions *get();
45
46 lldb_private::TypeSummaryOptions &ref();
47
48 const lldb_private::TypeSummaryOptions &ref() const;
49
50 void SetOptions(const lldb_private::TypeSummaryOptions *lldb_object_ptr);
51
52 private:
53 std::unique_ptr<lldb_private::TypeSummaryOptions> m_opaque_ap;
54 };
55
56 class SBTypeSummary {
57 public:
58 SBTypeSummary();
59
60 // Native function summary formatter callback
61 typedef bool (*FormatCallback)(SBValue, SBTypeSummaryOptions, SBStream &);
62
63 static SBTypeSummary
64 CreateWithSummaryString(const char *data,
65 uint32_t options = 0); // see lldb::eTypeOption values
66
67 static SBTypeSummary
68 CreateWithFunctionName(const char *data,
69 uint32_t options = 0); // see lldb::eTypeOption values
70
71 static SBTypeSummary
72 CreateWithScriptCode(const char *data,
73 uint32_t options = 0); // see lldb::eTypeOption values
74
75 static SBTypeSummary CreateWithCallback(FormatCallback cb,
76 uint32_t options = 0,
77 const char *description = nullptr);
78
79 SBTypeSummary(const lldb::SBTypeSummary &rhs);
80
81 ~SBTypeSummary();
82
83 bool IsValid() const;
84
85 bool IsFunctionCode();
86
87 bool IsFunctionName();
88
89 bool IsSummaryString();
90
91 const char *GetData();
92
93 void SetSummaryString(const char *data);
94
95 void SetFunctionName(const char *data);
96
97 void SetFunctionCode(const char *data);
98
99 uint32_t GetOptions();
100
101 void SetOptions(uint32_t);
102
103 bool GetDescription(lldb::SBStream &description,
104 lldb::DescriptionLevel description_level);
105
106 lldb::SBTypeSummary &operator=(const lldb::SBTypeSummary &rhs);
107
108 bool DoesPrintValue(lldb::SBValue value);
109
110 bool IsEqualTo(lldb::SBTypeSummary &rhs);
111
112 bool operator==(lldb::SBTypeSummary &rhs);
113
114 bool operator!=(lldb::SBTypeSummary &rhs);
115
116 protected:
117 friend class SBDebugger;
118 friend class SBTypeCategory;
119 friend class SBValue;
120
121 lldb::TypeSummaryImplSP GetSP();
122
123 void SetSP(const lldb::TypeSummaryImplSP &typefilter_impl_sp);
124
125 lldb::TypeSummaryImplSP m_opaque_sp;
126
127 SBTypeSummary(const lldb::TypeSummaryImplSP &);
128
129 bool CopyOnWrite_Impl();
130
131 bool ChangeSummaryType(bool want_script);
132 };
133
134 } // namespace lldb
135
136 #endif // LLDB_SBTypeSummary_h_
lldb::SBTypeSummary::CreateWithScriptCode
static SBTypeSummary CreateWithScriptCode(const char *data, uint32_t options=0)
lldb::SBTypeSummary::SBValue
friend class SBValue
Definition: SBTypeSummary.h:119
lldb::SBTypeSummary::operator==
bool operator==(lldb::SBTypeSummary &rhs)
lldb::SBTypeSummary::GetData
const char * GetData()
lldb::SBTypeSummary
Definition: SBTypeSummary.h:56
lldb::SBTypeCategory
Definition: SBTypeCategory.h:18
SBDefines.h
lldb::SBTypeSummary::SBTypeSummary
SBTypeSummary()
lldb::SBTypeSummary::operator!=
bool operator!=(lldb::SBTypeSummary &rhs)
lldb::SBTypeSummary::GetOptions
uint32_t GetOptions()
lldb::SBTypeSummary::FormatCallback
bool(* FormatCallback)(SBValue, SBTypeSummaryOptions, SBStream &)
Definition: SBTypeSummary.h:61
lldb::SBValue
Definition: SBValue.h:22
lldb::SBTypeSummary::ChangeSummaryType
bool ChangeSummaryType(bool want_script)
lldb::SBTypeSummary::IsSummaryString
bool IsSummaryString()
lldb::SBTypeSummary::GetSP
lldb::TypeSummaryImplSP GetSP()
lldb::SBTypeSummary::GetDescription
bool GetDescription(lldb::SBStream &description, lldb::DescriptionLevel description_level)
lldb::SBTypeSummary::SetFunctionCode
void SetFunctionCode(const char *data)
lldb::SBTypeSummary::SetSP
void SetSP(const lldb::TypeSummaryImplSP &typefilter_impl_sp)
lldb::SBTypeSummary::IsFunctionCode
bool IsFunctionCode()
lldb::SBTypeSummary::operator=
lldb::SBTypeSummary & operator=(const lldb::SBTypeSummary &rhs)
lldb::SBDebugger
Definition: SBDebugger.h:35
lldb::SBTypeSummary::m_opaque_sp
lldb::TypeSummaryImplSP m_opaque_sp
Definition: SBTypeSummary.h:125
lldb::SBTypeSummary::SetSummaryString
void SetSummaryString(const char *data)
lldb::SBTypeSummary::SetFunctionName
void SetFunctionName(const char *data)
lldb::SBTypeSummaryOptions
Definition: SBTypeSummary.h:17
lldb::SBTypeSummary::DoesPrintValue
bool DoesPrintValue(lldb::SBValue value)
lldb::SBTypeSummary::SetOptions
void SetOptions(uint32_t)
lldb::SBTypeSummary::CopyOnWrite_Impl
bool CopyOnWrite_Impl()
lldb::SBStream
Definition: SBStream.h:19
lldb::SBTypeSummary::IsFunctionName
bool IsFunctionName()
lldb::SBTypeSummary::CreateWithCallback
static SBTypeSummary CreateWithCallback(FormatCallback cb, uint32_t options=0, const char *description=nullptr)
lldb::SBTypeSummary::IsEqualTo
bool IsEqualTo(lldb::SBTypeSummary &rhs)
lldb::SBTypeSummaryOptions
class LLDB_API SBTypeSummaryOptions
Definition: SBDefines.h:91
lldb::SBTypeSummary::CreateWithSummaryString
static SBTypeSummary CreateWithSummaryString(const char *data, uint32_t options=0)
lldb::SBTypeSummary::~SBTypeSummary
~SBTypeSummary()
lldb::SBTypeSummary::CreateWithFunctionName
static SBTypeSummary CreateWithFunctionName(const char *data, uint32_t options=0)
lldb::SBTypeSummary::IsValid
bool IsValid() const