Пример #1
0
 private void OnServerDisconnected(ServerDisconnectedEventArgs e)
 {
     if (ServerDisconnected != null)
     {
         ServerDisconnected(this, e);
     }
 }
Пример #2
0
 /// <summary>
 /// Handles a server disconnecting.
 /// </summary>
 /// <param name="sender">The <see cref="ServerManager"/></param>
 /// <param name="e">The event args.</param>
 private void ServerDisconnected(object sender, ServerDisconnectedEventArgs e)
 {
     Interlocked.Increment(ref serverDisconnectedEvents);
 }
Пример #3
0
 private static void HandleServerDisconnected(object sender, ServerDisconnectedEventArgs e)
 {
     Console.WriteLine($"{DateTime.Now} - Disconected From: {e.Server}:{e.Port}{Environment.NewLine}");
 }
Пример #4
0
 private void HandleServerDisconnected(object sender, ServerDisconnectedEventArgs e)
 {
     LogListBox.Items.Add(string.Format("{0} - Odłączono do serwera: {1}:{2}", DateTime.Now, e.ServerIp, e.ServerPort));
 }