Backed out changeset b71c8c052463 (bug 1943846) for causing mass failures. CLOSED...
[gecko.git] / devtools / server / tests / chrome / hello-actor.js
blobeabb4a6773f3dd77d0ca1897b690df0c3f21d9a2
1 /* Any copyright is dedicated to the Public Domain.
2 http://creativecommons.org/publicdomain/zero/1.0/ */
3 /* exported HelloActor */
4 "use strict";
6 const protocol = require("resource://devtools/shared/protocol.js");
8 const helloSpec = protocol.generateActorSpec({
9 typeName: "helloActor",
11 methods: {
12 count: {
13 request: {},
14 response: { count: protocol.RetVal("number") },
17 });
19 class HelloActor extends protocol.Actor {
20 constructor(conn) {
21 super(conn, helloSpec);
22 this.counter = 0;
25 count() {
26 return ++this.counter;