Ejemplo n.º 1
0
        private void MessagingConnectionHandler_OnStarted(object sender, StartMessagingConnectionEventArgs e)
        {
            var unsubscriber = e.MessageConnection.Subscribe <MyIPData>(next: async value =>
            {
                await roomConnection.TellMyIpAsync(e.UserId, value.IP.Address, value.IP.Port);
            });

            unsubscribers.Add(e.UserId, unsubscriber);
        }
Ejemplo n.º 2
0
 private void MessagingConnectionHandler_OnStarted(object sender, StartMessagingConnectionEventArgs e)
 {
     sendingAddresses.Add(e.UserId, null);
     receiveMessageUnsubscribers.Add(e.UserId, e.MessageConnection.Subscribe <MessageData>(next: data => { MessageDataHandle(e.UserId, data); }));
     messageConnections.Add(e.UserId, e.MessageConnection);
 }