LLDB mainline
|
#include <StructuredData.h>
Public Member Functions | |
Array () | |
~Array () override=default | |
bool | ForEach (std::function< bool(Object *object)> const &foreach_callback) const |
size_t | GetSize () const |
ObjectSP | operator[] (size_t idx) |
ObjectSP | GetItemAtIndex (size_t idx) const |
template<class IntType > | |
bool | GetItemAtIndexAsInteger (size_t idx, IntType &result) const |
template<class IntType > | |
bool | GetItemAtIndexAsInteger (size_t idx, IntType &result, IntType default_val) const |
bool | GetItemAtIndexAsString (size_t idx, llvm::StringRef &result) const |
bool | GetItemAtIndexAsString (size_t idx, llvm::StringRef &result, llvm::StringRef default_val) const |
bool | GetItemAtIndexAsString (size_t idx, ConstString &result) const |
bool | GetItemAtIndexAsString (size_t idx, ConstString &result, const char *default_val) const |
bool | GetItemAtIndexAsDictionary (size_t idx, Dictionary *&result) const |
bool | GetItemAtIndexAsArray (size_t idx, Array *&result) const |
void | Push (const ObjectSP &item) |
void | AddItem (const ObjectSP &item) |
void | Serialize (llvm::json::OStream &s) const override |
void | GetDescription (lldb_private::Stream &s) const override |
![]() | |
Object (lldb::StructuredDataType t=lldb::eStructuredDataTypeInvalid) | |
virtual | ~Object ()=default |
virtual bool | IsValid () const |
virtual void | Clear () |
lldb::StructuredDataType | GetType () const |
void | SetType (lldb::StructuredDataType t) |
Array * | GetAsArray () |
Dictionary * | GetAsDictionary () |
Integer * | GetAsInteger () |
uint64_t | GetIntegerValue (uint64_t fail_value=0) |
Float * | GetAsFloat () |
double | GetFloatValue (double fail_value=0.0) |
Boolean * | GetAsBoolean () |
bool | GetBooleanValue (bool fail_value=false) |
String * | GetAsString () |
llvm::StringRef | GetStringValue (const char *fail_value=nullptr) |
Generic * | GetAsGeneric () |
ObjectSP | GetObjectForDotSeparatedPath (llvm::StringRef path) |
void | DumpToStdout (bool pretty_print=true) const |
virtual void | Serialize (llvm::json::OStream &s) const =0 |
void | Dump (lldb_private::Stream &s, bool pretty_print=true) const |
virtual void | GetDescription (lldb_private::Stream &s) const |
Protected Types | |
typedef std::vector< ObjectSP > | collection |
Protected Attributes | |
collection | m_items |
Definition at line 171 of file StructuredData.h.
|
protected |
Definition at line 289 of file StructuredData.h.
|
inline |
Definition at line 173 of file StructuredData.h.
|
overridedefault |
|
inline |
Definition at line 282 of file StructuredData.h.
References m_items.
Referenced by lldb_private::PlatformDarwin::ExtractAppSpecificInfo(), lldb_private::InstrumentationRuntimeMainThreadChecker::RetrieveReportData(), lldb_private::InstrumentationRuntimeUBSan::RetrieveReportData(), and lldb_private::Target::SerializeBreakpointsToFile().
|
inline |
Definition at line 178 of file StructuredData.h.
References m_items.
Referenced by lldb_private::ScriptedThread::CalculateStopInfo(), lldb_private::StructuredDataDarwinLog::GetDescription(), SystemRuntimeMacOSX::GetExtendedBacktraceThread(), lldb::SBStructuredData::GetKeys(), lldb_private::Process::MapSupportedStructuredDataPlugins(), lldb_private::process_gdb_remote::ProcessGDBRemote::SetThreadStopInfo(), and lldb_private::process_gdb_remote::ProcessGDBRemote::UpdateThreadIDList().
|
overridevirtual |
Reimplemented from lldb_private::StructuredData::Object.
Definition at line 200 of file StructuredData.cpp.
References lldb_private::Stream::EOL(), lldb_private::Stream::GetIndentLevel(), lldb_private::Stream::Indent(), lldb_private::Stream::IndentLess(), lldb_private::Stream::IndentMore(), lldb_private::StructuredData::IsRecordType(), lldb_private::Stream::Printf(), lldb_private::Stream::PutChar(), and lldb_private::Stream::SetIndentLevel().
|
inline |
Definition at line 194 of file StructuredData.h.
References GetSize(), and m_items.
Referenced by lldb_private::Target::CreateBreakpointsFromFile(), lldb_private::PlatformDarwin::ExtractAppSpecificInfo(), lldb_private::Thread::GetDescription(), GetItemAtIndexAsArray(), GetItemAtIndexAsDictionary(), GetItemAtIndexAsInteger(), GetItemAtIndexAsString(), lldb_private::process_gdb_remote::GDBRemoteCommunicationClient::GetModulesInfo(), lldb_private::StructuredData::Object::GetObjectForDotSeparatedPath(), lldb_private::process_gdb_remote::ProcessGDBRemote::GetThreadStopInfoFromJSON(), lldb_private::process_gdb_remote::GDBRemoteCommunicationServerCommon::Handle_jModulesInfo(), CommandObjectBreakpointRead::CommandOptions::HandleOptionArgumentCompletion(), lldb_private::DynamicLoaderDarwin::JSONImageInformationIntoImageInfo(), and lldb_private::process_gdb_remote::ProcessGDBRemote::WillPublicStop().
|
inline |
Definition at line 270 of file StructuredData.h.
References lldb_private::StructuredData::Object::GetAsArray(), and GetItemAtIndex().
|
inline |
Definition at line 260 of file StructuredData.h.
References lldb_private::StructuredData::Object::GetAsDictionary(), and GetItemAtIndex().
Referenced by lldb_private::process_gdb_remote::GDBRemoteCommunicationClient::QueryGDBServer(), and lldb_private::DynamicRegisterInfo::SetRegisterInfo().
|
inline |
Definition at line 202 of file StructuredData.h.
References GetItemAtIndex().
Referenced by lldb_private::BreakpointResolverName::CreateFromStructuredData(), lldb_private::InstrumentationRuntimeTSan::GetFirstNonInternalFramePc(), GetItemAtIndexAsInteger(), and lldb_private::DynamicRegisterInfo::SetRegisterInfo().
|
inline |
Definition at line 214 of file StructuredData.h.
References GetItemAtIndexAsInteger().
|
inline |
Definition at line 241 of file StructuredData.h.
References GetItemAtIndex().
|
inline |
Definition at line 252 of file StructuredData.h.
References GetItemAtIndexAsString(), and lldb_private::ConstString::SetCString().
|
inline |
Definition at line 222 of file StructuredData.h.
References GetItemAtIndex().
Referenced by lldb_private::DynamicRegisterInfo::ByteOffsetFromComposite(), lldb_private::BreakpointResolverName::CreateFromStructuredData(), lldb_private::BreakpointResolverFileRegex::CreateFromStructuredData(), lldb_private::SearchFilterByModule::CreateFromStructuredData(), lldb_private::SearchFilterByModuleList::CreateFromStructuredData(), lldb_private::SearchFilterByModuleListAndCU::CreateFromStructuredData(), lldb_private::BreakpointOptions::CommandData::CreateFromStructuredData(), lldb_private::Breakpoint::CreateFromStructuredData(), GetItemAtIndexAsString(), CommandObjectBreakpointRead::CommandOptions::HandleOptionArgumentCompletion(), lldb_private::Breakpoint::SerializedBreakpointMatchesNames(), and lldb_private::DynamicRegisterInfo::SetRegisterInfo().
|
inline |
Definition at line 233 of file StructuredData.h.
References GetItemAtIndexAsString().
|
inline |
Definition at line 186 of file StructuredData.h.
References m_items.
Referenced by lldb_private::DynamicRegisterInfo::ByteOffsetFromComposite(), lldb_private::Target::CreateBreakpointsFromFile(), lldb_private::BreakpointResolverName::CreateFromStructuredData(), lldb_private::BreakpointResolverFileRegex::CreateFromStructuredData(), lldb_private::SearchFilterByModule::CreateFromStructuredData(), lldb_private::SearchFilterByModuleList::CreateFromStructuredData(), lldb_private::SearchFilterByModuleListAndCU::CreateFromStructuredData(), lldb_private::BreakpointOptions::CommandData::CreateFromStructuredData(), lldb_private::Breakpoint::CreateFromStructuredData(), lldb_private::PlatformDarwin::ExtractAppSpecificInfo(), lldb_private::Thread::GetDescription(), SystemRuntimeMacOSX::GetExtendedBacktraceThread(), lldb_private::InstrumentationRuntimeTSan::GetFirstNonInternalFramePc(), GetItemAtIndex(), lldb_private::process_gdb_remote::GDBRemoteCommunicationClient::GetModulesInfo(), lldb_private::process_gdb_remote::ProcessGDBRemote::GetThreadStopInfoFromJSON(), lldb_private::process_gdb_remote::GDBRemoteCommunicationServerCommon::Handle_jModulesInfo(), CommandObjectBreakpointRead::CommandOptions::HandleOptionArgumentCompletion(), lldb_private::DynamicLoaderDarwin::JSONImageInformationIntoImageInfo(), lldb_private::Process::MapSupportedStructuredDataPlugins(), lldb_private::process_gdb_remote::GDBRemoteCommunicationClient::QueryGDBServer(), lldb_private::Breakpoint::SerializedBreakpointMatchesNames(), lldb_private::DynamicRegisterInfo::SetRegisterInfo(), lldb_private::process_gdb_remote::ProcessGDBRemote::UpdateThreadIDList(), and lldb_private::process_gdb_remote::ProcessGDBRemote::WillPublicStop().
|
inline |
Definition at line 188 of file StructuredData.h.
References m_items.
|
inline |
Definition at line 280 of file StructuredData.h.
References m_items.
Referenced by lldb_private::process_gdb_remote::GDBRemoteCommunicationServerPlatform::Handle_jSignalsInfo().
|
overridevirtual |
Implements lldb_private::StructuredData::Object.
Definition at line 142 of file StructuredData.cpp.
|
protected |
Definition at line 290 of file StructuredData.h.
Referenced by AddItem(), ForEach(), GetItemAtIndex(), GetSize(), operator[](), and Push().