Пример #1
0
 public Reader(RpcSocket socket = null, Header header = null, Handler handler = null)
 {
     this.socket  = socket;
     this.header  = header;
     this.handler = handler;
     mS           = new MemoryStream();
     bR           = new BinaryReader(mS);
 }
Пример #2
0
 public Handler(Header header, string host, string service, int timeout)
 {
     try
     {
         this.header = header;
         this.socket = new RpcSocket(host, int.Parse(service), timeout);
     }
     catch (Exception ex)
     {
         throw new RpcException(string.Format("Error connecting to host:{0} service:{1} timeout:{2}"
                                              , host, service, timeout), ex);
     }
 }
Пример #3
0
 public Handler(Header header, RpcSocket socket)
 {
     this.header = header;
     this.socket = socket;
 }