5#ifndef V8_INSPECTOR_V8_INSPECTOR_SESSION_IMPL_H_
6#define V8_INSPECTOR_V8_INSPECTOR_SESSION_IMPL_H_
12#include "src/inspector/protocol/Forward.h"
13#include "src/inspector/protocol/Runtime.h"
14#include "src/inspector/protocol/Schema.h"
21class RemoteObjectIdBase;
22class V8ConsoleAgentImpl;
23class V8DebuggerAgentImpl;
24class V8DebuggerBarrier;
26class V8HeapProfilerAgentImpl;
27class V8ProfilerAgentImpl;
28class V8RuntimeAgentImpl;
29class V8SchemaAgentImpl;
31using protocol::Response;
34 public protocol::FrontendChannel {
36 static std::unique_ptr<V8InspectorSessionImpl>
create(
40 std::shared_ptr<V8DebuggerBarrier>);
63 std::unique_ptr<protocol::Runtime::RemoteObject>
wrapObject(
65 bool generatePreview);
66 std::unique_ptr<protocol::Runtime::RemoteObject>
wrapTable(
76 std::vector<uint8_t>
state()
override;
77 std::vector<std::unique_ptr<protocol::Schema::API::Domain>>
supportedDomains()
80 std::unique_ptr<V8InspectorSession::Inspectable>)
override;
86 void resume(
bool terminateOnResume =
false)
override;
88 std::vector<std::unique_ptr<protocol::Debugger::API::SearchMatch>>
90 bool isRegex)
override;
94 std::unique_ptr<StringBuffer>* objectGroup)
override;
95 std::unique_ptr<protocol::Runtime::API::RemoteObject>
wrapObject(
97 bool generatePreview)
override;
104 bool includeCommandLineAPI =
false)
override;
105 void stop()
override;
115 std::shared_ptr<V8DebuggerBarrier>);
120 int callId, std::unique_ptr<protocol::Serializable> message)
override;
122 std::unique_ptr<protocol::Serializable> message)
override;
124 v8_crdtp::span<uint8_t> message)
override;
128 std::unique_ptr<protocol::Serializable> message);
136 std::unique_ptr<protocol::DictionaryValue>
m_state;
144 std::vector<std::unique_ptr<V8InspectorSession::Inspectable>>
V8Inspector::Channel * m_channel
void FlushProtocolNotifications() override
protocol::DictionaryValue * agentState(const String16 &name)
V8Inspector::ClientTrustLevel clientTrustLevel()
std::vector< std::unique_ptr< protocol::Schema::Domain > > supportedDomainsImpl()
std::unique_ptr< V8ConsoleAgentImpl > m_consoleAgent
V8InspectorSession::Inspectable * inspectedObject(unsigned num)
Response findInjectedScript(int contextId, InjectedScript *&)
std::unique_ptr< protocol::DictionaryValue > m_state
std::unique_ptr< V8DebuggerAgentImpl > m_debuggerAgent
V8InspectorSessionImpl & operator=(const V8InspectorSessionImpl &)=delete
std::vector< std::unique_ptr< protocol::Schema::API::Domain > > supportedDomains() override
void addInspectedObject(std::unique_ptr< V8InspectorSession::Inspectable >) override
std::vector< std::unique_ptr< V8InspectorSession::Inspectable > > m_inspectedObjects
void schedulePauseOnNextStatement(StringView breakReason, StringView breakDetails) override
std::unique_ptr< StringBuffer > serializeForFrontend(std::unique_ptr< protocol::Serializable > message)
V8ProfilerAgentImpl * profilerAgent()
void FallThrough(int callId, v8_crdtp::span< uint8_t > method, v8_crdtp::span< uint8_t > message) override
void resume(bool terminateOnResume=false) override
std::unique_ptr< protocol::Runtime::RemoteObject > wrapObject(v8::Local< v8::Context >, v8::Local< v8::Value >, const String16 &groupName, bool generatePreview)
V8Inspector::ClientTrustLevel m_clientTrustLevel
std::vector< std::unique_ptr< protocol::Debugger::API::SearchMatch > > searchInTextByLines(StringView text, StringView query, bool caseSensitive, bool isRegex) override
void releaseObjectGroup(const String16 &objectGroup)
void SendProtocolResponse(int callId, std::unique_ptr< protocol::Serializable > message) override
V8InspectorImpl * inspector() const
void SendProtocolNotification(std::unique_ptr< protocol::Serializable > message) override
std::unique_ptr< V8ProfilerAgentImpl > m_profilerAgent
V8ConsoleAgentImpl * consoleAgent()
void breakProgram(StringView breakReason, StringView breakDetails) override
static std::unique_ptr< V8InspectorSessionImpl > create(V8InspectorImpl *, int contextGroupId, int sessionId, V8Inspector::Channel *, StringView state, v8_inspector::V8Inspector::ClientTrustLevel, std::shared_ptr< V8DebuggerBarrier >)
std::unique_ptr< V8HeapProfilerAgentImpl > m_heapProfilerAgent
void setCustomObjectFormatterEnabled(bool)
bool m_customObjectFormatterEnabled
V8DebuggerAgentImpl * debuggerAgent()
std::vector< uint8_t > state() override
std::unique_ptr< V8SchemaAgentImpl > m_schemaAgent
protocol::UberDispatcher m_dispatcher
static const unsigned kInspectedObjectBufferSize
void discardInjectedScripts()
std::unique_ptr< protocol::Runtime::RemoteObject > wrapTable(v8::Local< v8::Context >, v8::Local< v8::Object > table, v8::MaybeLocal< v8::Array > columns)
bool use_binary_protocol_
void dispatchProtocolMessage(StringView message) override
~V8InspectorSessionImpl() override
Response unwrapObject(const String16 &objectId, v8::Local< v8::Value > *, v8::Local< v8::Context > *, String16 *objectGroup)
void triggerPreciseCoverageDeltaUpdate(StringView occasion) override
std::unique_ptr< V8RuntimeAgentImpl > m_runtimeAgent
V8SchemaAgentImpl * schemaAgent()
void cancelPauseOnNextStatement() override
V8InspectorSessionImpl(const V8InspectorSessionImpl &)=delete
V8HeapProfilerAgentImpl * heapProfilerAgent()
V8InspectorImpl * m_inspector
void reportAllContexts(V8RuntimeAgentImpl *)
EvaluateResult evaluate(v8::Local< v8::Context > context, StringView expression, bool includeCommandLineAPI=false) override
V8RuntimeAgentImpl * runtimeAgent()
int contextGroupId() const
void setSkipAllPauses(bool) override