Esempio n. 1
0
File: Gateway.cs Progetto: skwbr/UCS
 SocketRead(Socket socket, IncomingReadHandler readHandler, IncomingReadErrorHandler errorHandler = null)
 {
     Socket        = socket;
     _readHandler  = readHandler;
     _errorHandler = errorHandler;
     BeginReceive();
 }
Esempio n. 2
0
 private SocketRead(Socket socket, IncomingReadHandler readHandler, IncomingReadErrorHandler errorHandler = null)
 {
     Socket            = socket;
     this.readHandler  = readHandler;
     this.errorHandler = errorHandler;
     BeginReceive();
 }
        SocketRead(Socket socket, IncomingReadHandler readHandler, IncomingReadErrorHandler errorHandler = null)
        {
            this.socket = socket;
            this.readHandler = readHandler;
            this.errorHandler = errorHandler;

            BeginReceive();
        }
 public static SocketRead Begin(Socket socket, IncomingReadHandler readHandler, IncomingReadErrorHandler errorHandler = null)
 {
     return new SocketRead(socket, readHandler, errorHandler);
 }
Esempio n. 5
0
 public static SocketRead Begin(Socket socket,
                                IncomingReadHandler readHandler,
                                IncomingReadErrorHandler errorHandler = null)
 {
     return(new SocketRead(socket, readHandler, errorHandler));
 }
Esempio n. 6
0
 /// <summary>
 /// Initialize a new instance of the <see cref="Reader" /> class.
 /// </summary>
 /// <param name="_Socket">The socket.</param>
 /// <param name="_RHandler">The read handler.</param>
 public Reader(Socket _Socket, IncomingReadHandler _RHandler)
 {
     this.Socket   = _Socket;
     this.RHandler = _RHandler;
     this.Socket.BeginReceive(this.Buffer, 0, Constants.MaxBuffer, 0, this.OnReceive, this);
 }
Esempio n. 7
0
 public Reader(Socket socket, IncomingReadHandler readHandler)
 {
     Socket       = socket;
     _readHandler = readHandler;
     Socket.BeginReceive(_buffer, 0, 1024, 0, OnReceive, this);
 }
Esempio n. 8
0
 public Reader(Socket _Socket, IncomingReadHandler readHandler)
 {
     this.Socket       = _Socket;
     this._readHandler = readHandler;
     this.Socket.BeginReceive(this._buffer, 0, BufferSize, 0, this.OnReceive, this);
 }
Esempio n. 9
0
 public Gateway(Socket _Socket, IncomingReadHandler _RHandler)
 {
     this.m_vServerSocket = _Socket;
     this.RHandler        = _RHandler;
     this.m_vServerSocket.BeginReceive(this.Buffer, 0, Constants.MaxBuffer, 0, this.OnReceive, this);
 }