Esempio n. 1
0
 private void ProcessClientThread(NamedPipeServerStream pipeStream)
 {
     try
     {
         if (this.RequestReieved != null) //has event subscribers
         {
             var args = new PipeClientConnectionEventArgs(pipeStream);
             RequestReieved(this, args);
         }
     }
     catch (Exception e)
     {
         _log.Error("ProcessClientThread error: {0}", e.ToString().Flatten());
     }
     finally
     {
         if (pipeStream.IsConnected)
         {
             pipeStream.Close();
         }
         pipeStream.Dispose();
     }
 }
Esempio n. 2
0
 /// <summary>
 /// This method handles all requests on separate thread per client connection.
 /// There is one thread running this method for each connected client.
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="args"></param>
 private void ClientConnectionMade(object sender, PipeClientConnectionEventArgs args)
 {
     var stream = new BufferedStream(args.PipeStream);
     base.ProcessRequest(stream);
 }
Esempio n. 3
0
        /// <summary>
        /// This method handles all requests on separate thread per client connection.
        /// There is one thread running this method for each connected client.
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="args"></param>
        private void ClientConnectionMade(object sender, PipeClientConnectionEventArgs args)
        {
            var stream = new BufferedStream(args.PipeStream);

            base.ProcessRequest(stream);
        }
Esempio n. 4
0
 private void ProcessClientThread(NamedPipeServerStream pipeStream)
 {
     try
     {
         if (this.RequestReieved != null) //has event subscribers
         {
             var args = new PipeClientConnectionEventArgs(pipeStream);
             RequestReieved(this, args);
         }
     }
     catch (Exception e)
     {
         _log.Error("ProcessClientThread error: {0}", e.ToString().Flatten());
     }
     finally
     {
         if (pipeStream.IsConnected) pipeStream.Close();
         pipeStream.Dispose();
     }
 }