Exemple #1
0
 private void Update()
 {
     lock (lockResponseInputQ)
     {
         while (responseInputQ.Count > 0)
         {
             if (responseInputQ.First.Value != null)
             {
                 SocketResponse?.Invoke(responseInputQ.First.Value);
                 responseInputQ.RemoveFirst();
             }
         }
     }
 }
Exemple #2
0
 void QueueResponse(SocketResponse response)
 {
     lock (lockResponseInputQ)
         responseInputQ.AddLast(response);
 }