コード例 #1
0
 internal void ExecuteFinished(QueryThread qThread)
 {
     lock (_LockObj)
     {
         if (_Queue.Count > 0)
         {
             MessageReceiveEventArgs args = _Queue.Dequeue();
             qThread.ASendMessage((int)SQLClient.ConnectEvent.ExcuteSql, args);
         }
         else
         {
             _Pool.Push(qThread);
         }
     }
 }
コード例 #2
0
 internal void ExecuteSql(MessageReceiveEventArgs args)
 {
     lock (_LockObj)
     {
         if (_Pool.Count > 0)
         {
             QueryThread qThread = _Pool.Pop();
             qThread.ASendMessage((int)SQLClient.ConnectEvent.ExcuteSql, args);
         }
         else
         {
             _Queue.Enqueue(args);
         }
     }
 }