9#ifndef LLDB_API_SBDEBUGGER_H
10#define LLDB_API_SBDEBUGGER_H
18class CommandPluginInterfaceImplementation;
35 char const *,
unsigned long),
37 char const *d,
bool e);
39 bool IsActive()
const;
51 static const char *GetBroadcasterClass();
83 static const char *GetProgressFromEvent(
const lldb::SBEvent &event,
85 uint64_t &OUTPUT, uint64_t &OUTPUT,
88 static const char *GetProgressFromEvent(
const lldb::SBEvent &event,
89 uint64_t &progress_id,
90 uint64_t &completed, uint64_t &total,
91 bool &is_debugger_specific);
102 static void Initialize();
106 static void PrintStackTraceOnError();
108 static void PrintDiagnosticsOnError();
110 static void Terminate();
118 lldb::LogOutputCallback log_callback,
123 static
void MemoryPressureDetected();
125 explicit operator
bool() const;
127 bool IsValid() const;
146 void SetAsync(
bool b);
150 void SkipLLDBInitFiles(
bool b);
152 void SkipAppInitFiles(
bool b);
155 void SetInputFileHandle(FILE *f,
bool transfer_ownership);
157 void SetOutputFileHandle(FILE *f,
bool transfer_ownership);
159 void SetErrorFileHandle(FILE *f,
bool transfer_ownership);
163 FILE *GetInputFileHandle();
165 FILE *GetOutputFileHandle();
167 FILE *GetErrorFileHandle();
170 SBError SetInputString(
const char *data);
190 void SaveInputTerminalState();
192 void RestoreInputTerminalState();
196 void HandleCommand(
const char *command);
198 void RequestInterrupt();
199 void CancelInterruptRequest();
200 bool InterruptRequested();
206 "Use HandleProcessEvent(const SBProcess &, const SBEvent &, SBFile, "
207 "SBFile) or HandleProcessEvent(const SBProcess &, const SBEvent &, "
209 "HandleProcessEvent(const SBProcess &, const SBEvent &, SBFile, SBFile)")
225 lldb::SBTarget CreateTarget(
const char *filename,
const char *target_triple,
226 const char *platform_name,
229 lldb::SBTarget CreateTargetWithFileAndTargetTriple(
const char *filename,
230 const char *target_triple);
233 const char *archname);
251 uint32_t GetNumTargets();
255 void SetSelectedTarget(
SBTarget &target);
262 uint32_t GetNumPlatforms();
271 uint32_t GetNumAvailablePlatforms();
286 bool SetCurrentPlatformSDKRoot(
const char *sysroot);
290 bool SetUseExternalEditor(
bool input);
292 bool GetUseExternalEditor();
294 bool SetUseColor(
bool use_color);
296 bool GetUseColor()
const;
298 bool SetUseSourceCache(
bool use_source_cache);
300 bool GetUseSourceCache()
const;
302 static bool GetDefaultArchitecture(
char *arch_name,
size_t arch_name_len);
304 static bool SetDefaultArchitecture(
const char *arch_name);
310 static const char *GetVersionString();
320 bool EnableLog(
const char *channel,
const char **categories);
329 "DispatchInput(const void *, size_t)")
330 void DispatchInput(
void *baton, const
void *data,
size_t data_len);
333 void DispatchInput(
const void *data,
size_t data_len);
335 void DispatchInputInterrupt();
337 void DispatchInputEndOfFile();
343 const char *GetInstanceName();
347 static lldb::SBError SetInternalVariable(
const char *var_name,
349 const char *debugger_instance_name);
352 GetInternalVariableValue(
const char *var_name,
353 const char *debugger_instance_name);
357 uint32_t GetTerminalWidth()
const;
359 void SetTerminalWidth(uint32_t term_width);
363 const char *GetPrompt()
const;
365 void SetPrompt(
const char *prompt);
367 const char *GetReproducerPath()
const;
378 bool GetCloseInputOnEOF() const;
381 void SetCloseInputOnEOF(
bool b);
389 bool DeleteCategory(const
char *category_name);
391 uint32_t GetNumCategories();
417 void RunCommandInterpreter(
bool auto_handle_events,
bool spawn_thread);
444 %apply
int& INOUT {
int& num_errors };
445 %apply
bool& INOUT {
bool& quit_requested };
446 %apply
bool& INOUT {
bool& stopped_for_crash };
448 void RunCommandInterpreter(
bool auto_handle_events,
bool spawn_thread,
449 SBCommandInterpreterRunOptions &options,
450 int &num_errors,
bool &quit_requested,
451 bool &stopped_for_crash);
455 RunCommandInterpreter(
const SBCommandInterpreterRunOptions &options);
469 const SBFileSpec &trace_description_file);
473 friend class lldb_private::python::SWIGBridge;
static llvm::raw_ostream & error(Stream &strm)
#define LLDB_DEPRECATED_FIXME(MSG, FIX)
#define LLDB_DEPRECATED(MSG)
LLDB_DEPRECATED_FIXME("Use DispatchInput(const void *, size_t)", "DispatchInput(const void *, size_t)") void DispatchInput(void *baton
lldb::DebuggerSP m_opaque_sp
void HandleProcessEvent(const lldb::SBProcess &process, const lldb::SBEvent &event, FileSP out, FileSP err)
LLDB_DEPRECATED_FIXME("Use HandleProcessEvent(const SBProcess &, const SBEvent &, SBFile, " "SBFile) or HandleProcessEvent(const SBProcess &, const SBEvent &, " "FileSP, FileSP)", "HandleProcessEvent(const SBProcess &, const SBEvent &, SBFile, SBFile)") void HandleProcessEvent(const lldb void HandleProcessEvent(const lldb::SBProcess &process, const lldb::SBEvent &event, SBFile out, SBFile err)
A class to manage flag bits.
A class that represents a running process on the host machine.
ScriptLanguage
Script interpreter types.
StateType
Process and Thread States.
LanguageType
Programming language type.
std::shared_ptr< lldb_private::Process > ProcessSP
std::shared_ptr< lldb_private::Debugger > DebuggerSP
void(* SBDebuggerDestroyCallback)(lldb::user_id_t debugger_id, void *baton)
void(* LogOutputCallback)(const char *, void *baton)
std::shared_ptr< lldb_private::File > FileSP
class LLDB_API SBCommandInterpreterRunResult
InputReaderGranularity
Token size/granularities for Input Readers.