/// <summary> /// Передает всем клиентам информацию о сессии. /// </summary> public void ShareServerSessionForConnections(SessionStateMessage msg) { foreach (var userConnection in Connections) { userConnection.Connection.Send <SessionStateMessage>(msg); } }
/// <summary> /// Обновляет информацию о сессии у пользователя. /// </summary> private void ShareServerSession(NetworkConnection clientConnection, SessionStateMessage msg) { if (Session == null) { return; } clientConnection.Send <SessionStateMessage>(Session.StateMessage); }