public void Register(string key, PacketStream stream) { lock(_locker) _streamByKey.Add(key, stream); _sendQByKey.Add(key, new ConcurrentQueue<Packet>()); _recvQByKey.Add(key, new ConcurrentQueue<Packet>()); }
void AddClient(string name, PacketStream stream) { _messenger.Register(name, stream); }