UNPKG

457 BJavaScriptView Raw
1'use strict';
2
3Object.defineProperty(exports, '__esModule', { value: true });
4
5var children = /*#__PURE__*/new Map();
6var sessionIdIndex = 0;
7var registry = {
8 bookId: function () {
9 return "x:".concat(sessionIdIndex++);
10 },
11 register: function (id, actor) {
12 children.set(id, actor);
13 return id;
14 },
15 get: function (id) {
16 return children.get(id);
17 },
18 free: function (id) {
19 children.delete(id);
20 }
21};
22
23exports.registry = registry;