LLDB API Documentation

Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | Friends | List of all members
lldb::SBCommandInterpreter Class Reference

#include <SBCommandInterpreter.h>

Public Types

enum  {
  eBroadcastBitThreadShouldExit = (1 << 0), eBroadcastBitResetPrompt = (1 << 1), eBroadcastBitQuitCommandReceived = (1 << 2), eBroadcastBitAsynchronousOutputData = (1 << 3),
  eBroadcastBitAsynchronousErrorData = (1 << 4)
}
 

Public Member Functions

 SBCommandInterpreter (const lldb::SBCommandInterpreter &rhs)
 
 ~SBCommandInterpreter ()
 
const lldb::SBCommandInterpreteroperator= (const lldb::SBCommandInterpreter &rhs)
 
bool IsValid () const
 
bool CommandExists (const char *cmd)
 
bool AliasExists (const char *cmd)
 
lldb::SBBroadcaster GetBroadcaster ()
 
bool HasCommands ()
 
bool HasAliases ()
 
bool HasAliasOptions ()
 
lldb::SBProcess GetProcess ()
 
lldb::SBDebugger GetDebugger ()
 
lldb::SBCommand AddMultiwordCommand (const char *name, const char *help)
 
lldb::SBCommand AddCommand (const char *name, lldb::SBCommandPluginInterface *impl, const char *help)
 
lldb::SBCommand AddCommand (const char *name, lldb::SBCommandPluginInterface *impl, const char *help, const char *syntax)
 
void SourceInitFileInHomeDirectory (lldb::SBCommandReturnObject &result)
 
void SourceInitFileInCurrentWorkingDirectory (lldb::SBCommandReturnObject &result)
 
lldb::ReturnStatus HandleCommand (const char *command_line, lldb::SBCommandReturnObject &result, bool add_to_history=false)
 
lldb::ReturnStatus HandleCommand (const char *command_line, SBExecutionContext &exe_ctx, SBCommandReturnObject &result, bool add_to_history=false)
 
void HandleCommandsFromFile (lldb::SBFileSpec &file, lldb::SBExecutionContext &override_context, lldb::SBCommandInterpreterRunOptions &options, lldb::SBCommandReturnObject result)
 
int HandleCompletion (const char *current_line, const char *cursor, const char *last_char, int match_start_point, int max_return_elements, lldb::SBStringList &matches)
 
int HandleCompletion (const char *current_line, uint32_t cursor_pos, int match_start_point, int max_return_elements, lldb::SBStringList &matches)
 
bool SetCommandOverrideCallback (const char *command_name, lldb::CommandOverrideCallback callback, void *baton)
 
 SBCommandInterpreter (lldb_private::CommandInterpreter *interpreter_ptr=nullptr)
 
bool IsActive ()
 
const char * GetIOHandlerControlSequence (char ch)
 
bool GetPromptOnQuit ()
 
void SetPromptOnQuit (bool b)
 
void ResolveCommand (const char *command_line, SBCommandReturnObject &result)
 

Static Public Member Functions

static const char * GetArgumentTypeAsCString (const lldb::CommandArgumentType arg_type)
 
static const char * GetArgumentDescriptionAsCString (const lldb::CommandArgumentType arg_type)
 
static bool EventIsCommandInterpreterEvent (const lldb::SBEvent &event)
 
static const char * GetBroadcasterClass ()
 

Protected Member Functions

lldb_private::CommandInterpreter & ref ()
 
lldb_private::CommandInterpreter * get ()
 
void reset (lldb_private::CommandInterpreter *)
 

Friends

class SBDebugger
 

Detailed Description

Definition at line 66 of file SBCommandInterpreter.h.

Member Enumeration Documentation

anonymous enum
Enumerator
eBroadcastBitThreadShouldExit 
eBroadcastBitResetPrompt 
eBroadcastBitQuitCommandReceived 
eBroadcastBitAsynchronousOutputData 
eBroadcastBitAsynchronousErrorData 

Definition at line 68 of file SBCommandInterpreter.h.

Constructor & Destructor Documentation

lldb::SBCommandInterpreter::SBCommandInterpreter ( const lldb::SBCommandInterpreter rhs)
lldb::SBCommandInterpreter::~SBCommandInterpreter ( )
lldb::SBCommandInterpreter::SBCommandInterpreter ( lldb_private::CommandInterpreter *  interpreter_ptr = nullptr)

Member Function Documentation

lldb::SBCommand lldb::SBCommandInterpreter::AddCommand ( const char *  name,
lldb::SBCommandPluginInterface impl,
const char *  help 
)
lldb::SBCommand lldb::SBCommandInterpreter::AddCommand ( const char *  name,
lldb::SBCommandPluginInterface impl,
const char *  help,
const char *  syntax 
)
lldb::SBCommand lldb::SBCommandInterpreter::AddMultiwordCommand ( const char *  name,
const char *  help 
)
bool lldb::SBCommandInterpreter::AliasExists ( const char *  cmd)
bool lldb::SBCommandInterpreter::CommandExists ( const char *  cmd)
static bool lldb::SBCommandInterpreter::EventIsCommandInterpreterEvent ( const lldb::SBEvent event)
static
lldb_private::CommandInterpreter* lldb::SBCommandInterpreter::get ( )
protected
static const char* lldb::SBCommandInterpreter::GetArgumentDescriptionAsCString ( const lldb::CommandArgumentType  arg_type)
static
static const char* lldb::SBCommandInterpreter::GetArgumentTypeAsCString ( const lldb::CommandArgumentType  arg_type)
static
lldb::SBBroadcaster lldb::SBCommandInterpreter::GetBroadcaster ( )
static const char* lldb::SBCommandInterpreter::GetBroadcasterClass ( )
static
lldb::SBDebugger lldb::SBCommandInterpreter::GetDebugger ( )
const char* lldb::SBCommandInterpreter::GetIOHandlerControlSequence ( char  ch)

Get the string that needs to be written to the debugger stdin file handle when a control character is typed.

Some GUI programs will intercept "control + char" sequences and want to have them do what normally would happen when using a real terminal, so this function allows GUI programs to emulate this functionality.

Parameters
[in]chThe character that was typed along with the control key
Returns
The string that should be written into the file handle that is feeding the input stream for the debugger, or nullptr if there is no string for this control key.
lldb::SBProcess lldb::SBCommandInterpreter::GetProcess ( )
bool lldb::SBCommandInterpreter::GetPromptOnQuit ( )
lldb::ReturnStatus lldb::SBCommandInterpreter::HandleCommand ( const char *  command_line,
lldb::SBCommandReturnObject result,
bool  add_to_history = false 
)
lldb::ReturnStatus lldb::SBCommandInterpreter::HandleCommand ( const char *  command_line,
SBExecutionContext exe_ctx,
SBCommandReturnObject result,
bool  add_to_history = false 
)
void lldb::SBCommandInterpreter::HandleCommandsFromFile ( lldb::SBFileSpec file,
lldb::SBExecutionContext override_context,
lldb::SBCommandInterpreterRunOptions options,
lldb::SBCommandReturnObject  result 
)
int lldb::SBCommandInterpreter::HandleCompletion ( const char *  current_line,
const char *  cursor,
const char *  last_char,
int  match_start_point,
int  max_return_elements,
lldb::SBStringList matches 
)
int lldb::SBCommandInterpreter::HandleCompletion ( const char *  current_line,
uint32_t  cursor_pos,
int  match_start_point,
int  max_return_elements,
lldb::SBStringList matches 
)
bool lldb::SBCommandInterpreter::HasAliases ( )
bool lldb::SBCommandInterpreter::HasAliasOptions ( )
bool lldb::SBCommandInterpreter::HasCommands ( )
bool lldb::SBCommandInterpreter::IsActive ( )

Return true if the command interpreter is the active IO handler.

This indicates that any input coming into the debugger handles will go to the command interpreter and will result in LLDB command line commands being executed.

bool lldb::SBCommandInterpreter::IsValid ( ) const
const lldb::SBCommandInterpreter& lldb::SBCommandInterpreter::operator= ( const lldb::SBCommandInterpreter rhs)
lldb_private::CommandInterpreter& lldb::SBCommandInterpreter::ref ( )
protected
void lldb::SBCommandInterpreter::reset ( lldb_private::CommandInterpreter *  )
protected
void lldb::SBCommandInterpreter::ResolveCommand ( const char *  command_line,
SBCommandReturnObject result 
)

Resolve the command just as HandleCommand would, expanding abbreviations and aliases. If successful, result->GetOutput has the full expansion.

bool lldb::SBCommandInterpreter::SetCommandOverrideCallback ( const char *  command_name,
lldb::CommandOverrideCallback  callback,
void *  baton 
)
void lldb::SBCommandInterpreter::SetPromptOnQuit ( bool  b)
void lldb::SBCommandInterpreter::SourceInitFileInCurrentWorkingDirectory ( lldb::SBCommandReturnObject result)
void lldb::SBCommandInterpreter::SourceInitFileInHomeDirectory ( lldb::SBCommandReturnObject result)

Friends And Related Function Documentation

friend class SBDebugger
friend

Definition at line 225 of file SBCommandInterpreter.h.


The documentation for this class was generated from the following file: