Source
Future<WorkerSession> createSession([initial]) async { var s = generateBasicId(length: 25); var session = new _WorkerSession(this, s, true, initial); _sendPort.send({"t": "session.created", "s": s, "n": initial}); await ((_sessionReady[s] = new Completer.sync()).future); _ourSessions[s] = session; return session; }