Example #1
0
        /// <summary>
        /// Updates all SignalR clients with new information
        /// </summary>
        /// <returns>A Task representing the operation</returns>
        private static async Task UpdateAllSignalRClients()
        {
            string responseContent = GetServerlistJson();

            await HubConnectionExtensions.InvokeAsync(SignalRConnection, "SendUpdateAll", responseContent);
        }
Example #2
0
        /// <summary>
        /// Sends a specific SignalR client updated information
        /// </summary>
        /// <param name="clientId">The client that connected</param>
        /// <returns>A Task representing the operation</returns>
        private static async Task SignalRClientConnected(string clientId)
        {
            string responseContent = GetServerlistJson();

            await HubConnectionExtensions.InvokeAsync(SignalRConnection, "SendUpdateSpecific", responseContent, clientId);
        }