dom/workers/nsIWorkerDebugger.idl
author Nicolas B. Pierron <nicolas.b.pierron@nbp.name>
Wed, 24 Oct 2018 15:07:53 +0200
changeset 443125 1bd322732a6e67a0caab2e0bf26ff0b20f01fc1a
parent 439131 31941d904a7c3df53ed5b4c9ecdc40025d865dfb
child 461631 7ba97389b18333d03d4c07e101d1b156ec9b692f
permissions -rw-r--r--
Bug 1502106 - Add a configure option to disable assume_unreachable spew. r=iain

#include "nsISupports.idl"

interface mozIDOMWindow;
interface nsIPrincipal;

[scriptable, uuid(9cf3b48e-361d-486a-8917-55cf8d00bb41)]
interface nsIWorkerDebuggerListener : nsISupports
{
  void onClose();

  void onError(in AString filename, in unsigned long lineno,
               in AString message);

  void onMessage(in AString message);
};

[scriptable, builtinclass, uuid(22f93aa3-8a05-46be-87e0-fa93bf8a8eff)]
interface nsIWorkerDebugger : nsISupports
{
  const unsigned long TYPE_DEDICATED = 0;
  const unsigned long TYPE_SHARED = 1;
  const unsigned long TYPE_SERVICE = 2;

  readonly attribute bool isClosed;

  readonly attribute bool isChrome;

  readonly attribute bool isInitialized;

  readonly attribute nsIWorkerDebugger parent;

  readonly attribute unsigned long type;

  readonly attribute AString url;

  readonly attribute mozIDOMWindow window;

  readonly attribute nsIPrincipal principal;

  readonly attribute unsigned long serviceWorkerID;

  void initialize(in AString url);

  [binaryname(PostMessageMoz)]
  void postMessage(in AString message);

  void addListener(in nsIWorkerDebuggerListener listener);

  void removeListener(in nsIWorkerDebuggerListener listener);
};