LLDB
mainline
llvm-project
lldb
source
Plugins
ScriptInterpreter
Python
Interfaces
ScriptedThreadPythonInterface.h
Go to the documentation of this file.
1
//===-- ScriptedThreadPythonInterface.h ------------------------*- C++ -*-===//
2
//
3
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4
// See https://llvm.org/LICENSE.txt for license information.
5
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6
//
7
//===----------------------------------------------------------------------===//
8
9
#ifndef LLDB_SOURCE_PLUGINS_SCRIPTINTERPRETER_PYTHON_INTERFACES_SCRIPTEDTHREADPYTHONINTERFACE_H
10
#define LLDB_SOURCE_PLUGINS_SCRIPTINTERPRETER_PYTHON_INTERFACES_SCRIPTEDTHREADPYTHONINTERFACE_H
11
12
#include "
ScriptedPythonInterface.h
"
13
#include "
lldb/Interpreter/Interfaces/ScriptedThreadInterface.h
"
14
#include <optional>
15
16
namespace
lldb_private
{
17
class
ScriptedThreadPythonInterface
:
public
ScriptedThreadInterface
,
18
public
ScriptedPythonInterface
{
19
public
:
20
ScriptedThreadPythonInterface
(
ScriptInterpreterPythonImpl
&interpreter);
21
22
llvm::Expected<StructuredData::GenericSP>
23
CreatePluginObject
(llvm::StringRef class_name,
ExecutionContext
&exe_ctx,
24
StructuredData::DictionarySP
args_sp,
25
StructuredData::Generic
*script_obj =
nullptr
)
override
;
26
27
llvm::SmallVector<AbstractMethodRequirement>
28
GetAbstractMethodRequirements
()
const override
{
29
return
llvm::SmallVector<AbstractMethodRequirement>(
30
{{
"get_stop_reason"
}, {
"get_register_context"
}});
31
}
32
33
lldb::tid_t
GetThreadID
()
override
;
34
35
std::optional<std::string>
GetName
()
override
;
36
37
lldb::StateType
GetState
()
override
;
38
39
std::optional<std::string>
GetQueue
()
override
;
40
41
StructuredData::DictionarySP
GetStopReason
()
override
;
42
43
StructuredData::ArraySP
GetStackFrames
()
override
;
44
45
StructuredData::DictionarySP
GetRegisterInfo
()
override
;
46
47
std::optional<std::string>
GetRegisterContext
()
override
;
48
49
StructuredData::ArraySP
GetExtendedInfo
()
override
;
50
51
std::optional<std::string>
GetScriptedFramePluginName
()
override
;
52
53
protected
:
54
lldb::ScriptedFrameInterfaceSP
CreateScriptedFrameInterface
()
override
;
55
};
56
}
// namespace lldb_private
57
58
#endif
// LLDB_SOURCE_PLUGINS_SCRIPTINTERPRETER_PYTHON_INTERFACES_SCRIPTEDTHREADPYTHONINTERFACE_H
ScriptedPythonInterface.h
ScriptedThreadInterface.h
lldb_private::ExecutionContext
"lldb/Target/ExecutionContext.h" A class that contains an execution context.
Definition
ExecutionContext.h:317
lldb_private::ScriptInterpreterPythonImpl
Definition
ScriptInterpreterPythonImpl.h:25
lldb_private::ScriptedPythonInterface::ScriptedPythonInterface
ScriptedPythonInterface(ScriptInterpreterPythonImpl &interpreter)
Definition
ScriptedPythonInterface.cpp:25
lldb_private::ScriptedThreadInterface
Definition
ScriptedThreadInterface.h:21
lldb_private::ScriptedThreadPythonInterface::GetQueue
std::optional< std::string > GetQueue() override
Definition
ScriptedThreadPythonInterface.cpp:75
lldb_private::ScriptedThreadPythonInterface::GetScriptedFramePluginName
std::optional< std::string > GetScriptedFramePluginName() override
Definition
ScriptedThreadPythonInterface.cpp:146
lldb_private::ScriptedThreadPythonInterface::GetStopReason
StructuredData::DictionarySP GetStopReason() override
Definition
ScriptedThreadPythonInterface.cpp:86
lldb_private::ScriptedThreadPythonInterface::GetAbstractMethodRequirements
llvm::SmallVector< AbstractMethodRequirement > GetAbstractMethodRequirements() const override
Definition
ScriptedThreadPythonInterface.h:28
lldb_private::ScriptedThreadPythonInterface::GetThreadID
lldb::tid_t GetThreadID() override
Definition
ScriptedThreadPythonInterface.cpp:42
lldb_private::ScriptedThreadPythonInterface::GetState
lldb::StateType GetState() override
Definition
ScriptedThreadPythonInterface.cpp:64
lldb_private::ScriptedThreadPythonInterface::GetRegisterInfo
StructuredData::DictionarySP GetRegisterInfo() override
Definition
ScriptedThreadPythonInterface.cpp:110
lldb_private::ScriptedThreadPythonInterface::GetRegisterContext
std::optional< std::string > GetRegisterContext() override
Definition
ScriptedThreadPythonInterface.cpp:122
lldb_private::ScriptedThreadPythonInterface::ScriptedThreadPythonInterface
ScriptedThreadPythonInterface(ScriptInterpreterPythonImpl &interpreter)
Definition
ScriptedThreadPythonInterface.cpp:27
lldb_private::ScriptedThreadPythonInterface::GetStackFrames
StructuredData::ArraySP GetStackFrames() override
Definition
ScriptedThreadPythonInterface.cpp:98
lldb_private::ScriptedThreadPythonInterface::CreateScriptedFrameInterface
lldb::ScriptedFrameInterfaceSP CreateScriptedFrameInterface() override
Definition
ScriptedThreadPythonInterface.cpp:158
lldb_private::ScriptedThreadPythonInterface::GetExtendedInfo
StructuredData::ArraySP GetExtendedInfo() override
Definition
ScriptedThreadPythonInterface.cpp:133
lldb_private::ScriptedThreadPythonInterface::CreatePluginObject
llvm::Expected< StructuredData::GenericSP > CreatePluginObject(llvm::StringRef class_name, ExecutionContext &exe_ctx, StructuredData::DictionarySP args_sp, StructuredData::Generic *script_obj=nullptr) override
Definition
ScriptedThreadPythonInterface.cpp:32
lldb_private::ScriptedThreadPythonInterface::GetName
std::optional< std::string > GetName() override
Definition
ScriptedThreadPythonInterface.cpp:53
lldb_private::StructuredData::Generic
Definition
StructuredData.h:558
lldb_private::StructuredData::DictionarySP
std::shared_ptr< Dictionary > DictionarySP
Definition
StructuredData.h:73
lldb_private::StructuredData::ArraySP
std::shared_ptr< Array > ArraySP
Definition
StructuredData.h:67
lldb_private
A class that represents a running process on the host machine.
Definition
SBAddressRange.h:14
lldb::StateType
StateType
Process and Thread States.
Definition
lldb-enumerations.h:74
lldb::tid_t
uint64_t tid_t
Definition
lldb-types.h:84
lldb::ScriptedFrameInterfaceSP
std::shared_ptr< lldb_private::ScriptedFrameInterface > ScriptedFrameInterfaceSP
Definition
lldb-forward.h:416
Generated on
for LLDB by
1.14.0