12#include "llvm/Support/WithColor.h"
21 if (event_data->GetFlavor() == T::GetFlavorString())
22 return static_cast<const T *
>(event_ptr->
GetData());
49 return GetEventDataFromEventImpl<ProgressEventData>(event_ptr);
61 llvm_unreachable(
"Fully covered switch above!");
66 ? llvm::HighlightColor::Warning
67 : llvm::HighlightColor::Error;
68 llvm::WithColor(s->
AsRawOstream(), color, llvm::ColorMode::Enable)
85 return GetEventDataFromEventImpl<DiagnosticEventData>(event_ptr);
89 static ConstString g_flavor(
"SymbolChangeEventData");
99 return GetEventDataFromEventImpl<SymbolChangeEventData>(event_ptr);
107 for (TargetSP target_sp : debugger_sp->GetTargetList().Targets()) {
108 if (ModuleSP module_sp =
111 std::lock_guard<std::recursive_mutex> guard(module_sp->GetMutex());
112 if (!module_sp->GetSymbolFileFileSpec())
116 module_list.
Append(module_sp);
117 target_sp->SymbolsDidLoad(module_list);
static const T * GetEventDataFromEventImpl(const Event *event_ptr)
A uniqued constant string class.
void Dump(Stream *s) const override
static ConstString GetFlavorString()
const std::string & GetMessage() const
llvm::StringRef GetPrefix() const
static const DiagnosticEventData * GetEventDataFromEvent(const Event *event_ptr)
ConstString GetFlavor() const override
A collection class for Module objects.
void Append(const lldb::ModuleSP &module_sp, bool notify=true)
Append a module to the module list.
FileSpec & GetSymbolFileSpec()
void Dump(Stream *s) const override
static const ProgressEventData * GetEventDataFromEvent(const Event *event_ptr)
ConstString GetFlavor() const override
static ConstString GetFlavorString()
A stream class that can stream formatted output to a file.
llvm::raw_ostream & AsRawOstream()
Returns a raw_ostream that forwards the data to this Stream object.
size_t Printf(const char *format,...) __attribute__((format(printf
Output printf formatted output to the stream.
size_t PutCString(llvm::StringRef cstr)
Output a C string to the stream.
virtual void Flush()=0
Flush the stream.
ConstString GetFlavor() const override
static const SymbolChangeEventData * GetEventDataFromEvent(const Event *event_ptr)
static ConstString GetFlavorString()
lldb::DebuggerWP m_debugger_wp
void DoOnRemoval(Event *event_ptr) override
A class that represents a running process on the host machine.