|
LLDB mainline
|
#include <ScriptedCommandPythonInterface.h>
Public Member Functions | |
| ScriptedCommandPythonInterface (ScriptInterpreterPythonImpl &interpreter) | |
| llvm::Expected< StructuredData::GenericSP > | CreatePluginObject (llvm::StringRef class_name, lldb::DebuggerSP debugger_sp) override |
| llvm::SmallVector< AbstractMethodRequirement > | GetAbstractMethodRequirements () const override |
| bool | RunRawCommand (llvm::StringRef args, ScriptedCommandSynchronicity synchronicity, CommandReturnObject &cmd_retobj, Status &error, const ExecutionContext &exe_ctx) override |
| bool | RunParsedCommand (Args &args, ScriptedCommandSynchronicity synchronicity, CommandReturnObject &cmd_retobj, Status &error, const ExecutionContext &exe_ctx) override |
| std::optional< std::string > | GetRepeatCommand (Args &args) override |
| StructuredData::DictionarySP | HandleArgumentCompletion (std::vector< std::string > &args, size_t args_pos, size_t char_in_arg) override |
| StructuredData::DictionarySP | HandleOptionArgumentCompletion (llvm::StringRef &long_option, size_t char_in_arg) override |
| bool | GetShortHelp (std::string &dest) override |
| bool | GetLongHelp (std::string &dest) override |
| uint32_t | GetFlags () override |
| StructuredData::ObjectSP | GetOptionsDefinition () override |
| StructuredData::ObjectSP | GetArgumentsDefinition () override |
| void | OptionParsingStarted () override |
| bool | SetOptionValue (ExecutionContext *exe_ctx, llvm::StringRef long_option, llvm::StringRef value) override |
| llvm::StringRef | GetPluginName () override |
| Public Member Functions inherited from lldb_private::ScriptedInterface | |
| ScriptedInterface ()=default | |
| virtual | ~ScriptedInterface ()=default |
| StructuredData::GenericSP | GetScriptObjectInstance () |
| const std::optional< ScriptedMetadata > & | GetScriptedMetadata () const |
| llvm::SmallVector< llvm::StringLiteral > const | GetAbstractMethods () const |
| Public Member Functions inherited from lldb_private::ScriptedPythonInterface | |
| ScriptedPythonInterface (ScriptInterpreterPythonImpl &interpreter) | |
| ~ScriptedPythonInterface () override=default | |
| llvm::Expected< FileSpec > | GetScriptedModulePath () override |
| llvm::Expected< std::map< llvm::StringLiteral, AbstractMethodCheckerPayload > > | CheckAbstractMethodImplementation (const python::PythonDictionary &class_dict) const |
| template<typename... Args> | |
| llvm::Expected< StructuredData::GenericSP > | CreatePluginObject (const ScriptedMetadata &scripted_metadata, StructuredData::Generic *script_obj, Args... args) |
| template<typename T = StructuredData::ObjectSP, typename... Args> | |
| T | CallStaticMethod (llvm::StringRef class_name, llvm::StringRef method_name, Status &error, Args &&...args) |
| Call a static method on a Python class without creating an instance. | |
| Public Member Functions inherited from lldb_private::PluginInterface | |
| PluginInterface ()=default | |
| virtual | ~PluginInterface ()=default |
| PluginInterface (const PluginInterface &)=delete | |
| PluginInterface & | operator= (const PluginInterface &)=delete |
Static Public Member Functions | |
| static void | Initialize () |
| static void | Terminate () |
| static llvm::StringRef | GetPluginNameStatic () |
| Static Public Member Functions inherited from lldb_private::ScriptedInterface | |
| template<typename Ret> | |
| static Ret | ErrorWithMessage (llvm::StringRef caller_name, llvm::StringRef error_msg, Status &error, LLDBLog log_category=LLDBLog::Process) |
| template<typename T = StructuredData::ObjectSP> | |
| static bool | CheckStructuredDataObject (llvm::StringRef caller, T obj, Status &error) |
| static bool | CreateInstance (lldb::ScriptLanguage language, ScriptedInterfaceUsages usages) |
Private Attributes | |
| lldb::DebuggerSP | m_debugger_sp |
Definition at line 17 of file ScriptedCommandPythonInterface.h.
| ScriptedCommandPythonInterface::ScriptedCommandPythonInterface | ( | ScriptInterpreterPythonImpl & | interpreter | ) |
Definition at line 29 of file ScriptedCommandPythonInterface.cpp.
References lldb_private::ScriptedPythonInterface::ScriptedPythonInterface().
|
overridevirtual |
Implements lldb_private::ScriptedCommandInterface.
Definition at line 34 of file ScriptedCommandPythonInterface.cpp.
References lldb_private::ScriptedPythonInterface::CreatePluginObject(), and m_debugger_sp.
|
inlineoverridevirtual |
Implements lldb_private::ScriptedInterface.
Definition at line 28 of file ScriptedCommandPythonInterface.h.
|
overridevirtual |
Reimplemented from lldb_private::ScriptedCommandInterface.
Definition at line 207 of file ScriptedCommandPythonInterface.cpp.
References lldb_private::ScriptedPythonInterface::Dispatch(), and error().
|
overridevirtual |
Reimplemented from lldb_private::ScriptedCommandInterface.
Definition at line 191 of file ScriptedCommandPythonInterface.cpp.
References lldb_private::ScriptedInterface::CheckStructuredDataObject(), lldb_private::ScriptedPythonInterface::Dispatch(), and error().
|
overridevirtual |
Reimplemented from lldb_private::ScriptedCommandInterface.
Definition at line 180 of file ScriptedCommandPythonInterface.cpp.
References lldb_private::ScriptedInterface::CheckStructuredDataObject(), lldb_private::ScriptedPythonInterface::Dispatch(), and error().
|
overridevirtual |
Reimplemented from lldb_private::ScriptedCommandInterface.
Definition at line 201 of file ScriptedCommandPythonInterface.cpp.
References lldb_private::ScriptedPythonInterface::Dispatch(), and error().
|
inlineoverridevirtual |
Implements lldb_private::PluginInterface.
Definition at line 74 of file ScriptedCommandPythonInterface.h.
References GetPluginNameStatic().
|
inlinestatic |
Definition at line 70 of file ScriptedCommandPythonInterface.h.
Referenced by GetPluginName(), and Initialize().
|
overridevirtual |
Reimplemented from lldb_private::ScriptedCommandInterface.
Definition at line 114 of file ScriptedCommandPythonInterface.cpp.
References lldb_private::ScriptedInterface::CheckStructuredDataObject(), lldb_private::ScriptedPythonInterface::Dispatch(), error(), and lldb_private::Args::GetQuotedCommandString().
|
overridevirtual |
Reimplemented from lldb_private::ScriptedCommandInterface.
Definition at line 169 of file ScriptedCommandPythonInterface.cpp.
References lldb_private::ScriptedInterface::CheckStructuredDataObject(), lldb_private::ScriptedPythonInterface::Dispatch(), and error().
|
overridevirtual |
Reimplemented from lldb_private::ScriptedCommandInterface.
Definition at line 127 of file ScriptedCommandPythonInterface.cpp.
References lldb_private::ScriptedInterface::CheckStructuredDataObject(), lldb_private::ScriptedPythonInterface::Dispatch(), error(), and lldb::eStructuredDataTypeInvalid.
|
overridevirtual |
Reimplemented from lldb_private::ScriptedCommandInterface.
Definition at line 142 of file ScriptedCommandPythonInterface.cpp.
References lldb_private::ScriptedInterface::CheckStructuredDataObject(), lldb_private::ScriptedPythonInterface::Dispatch(), error(), lldb::eStructuredDataTypeBoolean, and lldb::eStructuredDataTypeInvalid.
|
static |
Definition at line 235 of file ScriptedCommandPythonInterface.cpp.
References lldb_private::ScriptedInterface::CreateInstance(), lldb::eScriptedExtensionScriptedCommand, lldb::eScriptLanguagePython, GetPluginNameStatic(), and lldb_private::PluginManager::RegisterPlugin().
Referenced by lldb_private::ScriptInterpreterPythonInterfaces::Initialize().
|
overridevirtual |
Reimplemented from lldb_private::ScriptedCommandInterface.
Definition at line 212 of file ScriptedCommandPythonInterface.cpp.
References lldb_private::ScriptedPythonInterface::Dispatch(), and error().
|
overridevirtual |
Reimplemented from lldb_private::ScriptedCommandInterface.
Definition at line 81 of file ScriptedCommandPythonInterface.cpp.
References lldb_private::ScriptInterpreterPythonImpl::Locker::AcquireLock, lldb_private::ScriptedPythonInterface::Dispatch(), lldb::eReturnStatusFailed, error(), lldb_private::ScriptInterpreterPythonImpl::Locker::FreeLock, lldb_private::Status::FromErrorString(), lldb_private::CommandReturnObject::GetInteractive(), lldb_private::CommandReturnObject::GetStatus(), lldb_private::ScriptInterpreterPythonImpl::Locker::InitSession, m_debugger_sp, lldb_private::ScriptedPythonInterface::m_interpreter, lldb_private::ScriptInterpreterPythonImpl::Locker::NoSTDIN, and lldb_private::ScriptInterpreterPythonImpl::Locker::TearDownSession.
|
overridevirtual |
Reimplemented from lldb_private::ScriptedCommandInterface.
Definition at line 49 of file ScriptedCommandPythonInterface.cpp.
References lldb_private::ScriptInterpreterPythonImpl::Locker::AcquireLock, lldb_private::ScriptedPythonInterface::Dispatch(), lldb::eReturnStatusFailed, error(), lldb_private::ScriptInterpreterPythonImpl::Locker::FreeLock, lldb_private::Status::FromErrorString(), lldb_private::CommandReturnObject::GetInteractive(), lldb_private::CommandReturnObject::GetStatus(), lldb_private::ScriptInterpreterPythonImpl::Locker::InitSession, m_debugger_sp, lldb_private::ScriptedPythonInterface::m_interpreter, lldb_private::ScriptInterpreterPythonImpl::Locker::NoSTDIN, and lldb_private::ScriptInterpreterPythonImpl::Locker::TearDownSession.
|
overridevirtual |
Reimplemented from lldb_private::ScriptedCommandInterface.
Definition at line 217 of file ScriptedCommandPythonInterface.cpp.
References lldb_private::ScriptedInterface::CheckStructuredDataObject(), lldb_private::ScriptedPythonInterface::Dispatch(), and error().
|
static |
Definition at line 247 of file ScriptedCommandPythonInterface.cpp.
References lldb_private::ScriptedInterface::CreateInstance(), and lldb_private::PluginManager::UnregisterPlugin().
Referenced by lldb_private::ScriptInterpreterPythonInterfaces::Terminate().
|
private |
Definition at line 77 of file ScriptedCommandPythonInterface.h.
Referenced by CreatePluginObject(), RunParsedCommand(), and RunRawCommand().