Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nodejs/node.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEugene Ostroukhov <eostroukhov@chromium.org>2017-04-26 00:55:55 +0300
committerEugene Ostroukhov <eostroukhov@chromium.org>2017-05-04 20:40:24 +0300
commit3f48ab30420981f888ff2c69fc1ea5abb37f3f2e (patch)
tree36bdaeea37d4d4fcd65e961250baa2417ec21dab /src/inspector_agent.h
parent6ade7f360184da4ea63c8ad1b6a24dc4a2bf9655 (diff)
inspector: do not add 'inspector' property
'inspector' property is not an official API and should not be published on process object, where the user may discover it. This change was extracted from https://github.com/nodejs/node/pull/12263 that will be focused on creating JS bindings. PR-URL: https://github.com/nodejs/node/pull/12656 Reviewed-By: Aleksey Kozyatinskiy <kozyatinskiy@chromium.org> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Timothy Gu <timothygu99@gmail.com>
Diffstat (limited to 'src/inspector_agent.h')
-rw-r--r--src/inspector_agent.h18
1 files changed, 11 insertions, 7 deletions
diff --git a/src/inspector_agent.h b/src/inspector_agent.h
index 483ac52b550..a939f6c6ba0 100644
--- a/src/inspector_agent.h
+++ b/src/inspector_agent.h
@@ -17,11 +17,13 @@ class Environment;
} // namespace node
namespace v8 {
+class Context;
template <typename V>
class FunctionCallbackInfo;
template<typename T>
class Local;
class Message;
+class Object;
class Platform;
class Value;
} // namespace v8
@@ -61,19 +63,21 @@ class Agent {
void Disconnect();
void Dispatch(const v8_inspector::StringView& message);
void RunMessageLoop();
+ bool enabled() {
+ return enabled_;
+ }
+ void PauseOnNextJavascriptStatement(const std::string& reason);
+ static void InitJSBindings(v8::Local<v8::Object> target,
+ v8::Local<v8::Value> unused,
+ v8::Local<v8::Context> context,
+ void* priv);
private:
- static void CallAndPauseOnStart(const v8::FunctionCallbackInfo<v8::Value>&);
- static void InspectorConsoleCall(
- const v8::FunctionCallbackInfo<v8::Value>& info);
- static void InspectorWrapConsoleCall(
- const v8::FunctionCallbackInfo<v8::Value>& info);
-
node::Environment* parent_env_;
std::unique_ptr<NodeInspectorClient> inspector_;
std::unique_ptr<InspectorIo> io_;
v8::Platform* platform_;
- bool inspector_console_;
+ bool enabled_;
std::string path_;
DebugOptions debug_options_;
};