JSGlobalObjectDebuggable.h [plain text]
#ifndef JSGlobalObjectDebuggable_h
#define JSGlobalObjectDebuggable_h
#if ENABLE(REMOTE_INSPECTOR)
#include "JSGlobalObjectInspectorController.h"
#include "RemoteInspectionTarget.h"
#include <wtf/Noncopyable.h>
namespace Inspector {
class FrontendChannel;
enum class DisconnectReason;
}
namespace JSC {
class JSGlobalObject;
class JSGlobalObjectDebuggable final : public Inspector::RemoteInspectionTarget {
WTF_MAKE_FAST_ALLOCATED;
WTF_MAKE_NONCOPYABLE(JSGlobalObjectDebuggable);
public:
JSGlobalObjectDebuggable(JSGlobalObject&);
~JSGlobalObjectDebuggable() { }
Inspector::RemoteControllableTarget::Type type() const override { return Inspector::RemoteControllableTarget::Type::JavaScript; }
String name() const override;
bool hasLocalDebugger() const override { return false; }
void connect(Inspector::FrontendChannel*, bool automaticInspection) override;
void disconnect(Inspector::FrontendChannel*) override;
void dispatchMessageFromRemote(const String& message) override;
void pause() override;
bool automaticInspectionAllowed() const override { return true; }
void pauseWaitingForAutomaticInspection() override;
private:
JSGlobalObject& m_globalObject;
};
}
SPECIALIZE_TYPE_TRAITS_CONTROLLABLE_TARGET(JSC::JSGlobalObjectDebuggable, JavaScript);
#endif // ENABLE(REMOTE_INSPECTOR)
#endif // !defined(JSGlobalObjectDebuggable_h)