an implementation of a transport over sockets. example: SocketTransport t = new SocketTransport("localhost", 12345)
Inheritance: BaseTransport
Beispiel #1
0
        public static ProcTransport Connect(Process proc)
        {
            proc.Start();
            if (proc.StandardOutput.ReadLine() != "AGNOS")
            {
                throw new TransportException("process " + proc + " did not start correctly");
            }
            string     hostname  = proc.StandardOutput.ReadLine();
            int        port      = Int16.Parse(proc.StandardOutput.ReadLine());
            ITransport transport = new SocketTransport(hostname, port);

            return(new ProcTransport(proc, transport));
        }
Beispiel #2
0
 public static ProcTransport Connect(Process proc)
 {
     proc.Start ();
     if (proc.StandardOutput.ReadLine () != "AGNOS") {
         throw new TransportException ("process " + proc + " did not start correctly");
     }
     string hostname = proc.StandardOutput.ReadLine ();
     int port = Int16.Parse (proc.StandardOutput.ReadLine ());
     ITransport transport = new SocketTransport (hostname, port);
     return new ProcTransport (proc, transport);
 }
Beispiel #3
0
 public SslSocketTransport(IPAddress addr, int port) : this(SocketTransport._connect(addr, port))
 {
 }
Beispiel #4
0
 public SslSocketTransport(String host, int port) : this(SocketTransport._connect(host, port))
 {
 }