Ejemplo n.º 1
0
 /// <summary>
 ///
 /// </summary>
 /// <param name="localPort"></param>
 /// <param name="remIP"></param>
 /// <param name="remPort"></param>
 public SocketAgent(int localPort, string remIP, int remPort)
 {
     this._config = new SocketAgentConfig()
     {
         localPort = localPort,
         remIP     = remIP,
         remPort   = remPort,
     };
     _listen          = new SocketServer("0.0.0.0", localPort);
     _listen.Accepted = AcceptedCallback;
 }
Ejemplo n.º 2
0
 public SocketAgentClientSession(IPipelineSocket acceptSocket
                                 , SocketAgentConfig _config
                                 , SocketAgent SocketAgentServer
                                 )
 {
     this.SocketAgentServer = SocketAgentServer;
     this._config           = _config;
     this.acceptSocket      = acceptSocket;
     this.remSocket         = new PipelineSocket(1024);
     Initializer();
 }