Example #1
0
 public BaseHandler(Socket socket, BaseConfigModel connectionConfig = null, IMarshallProvider marshaller = null)
 {
     this.socket           = socket;
     this.connectionConfig = connectionConfig;
     if (this.socket == null)
     {
         if (this.connectionConfig == null)
         {
             throw new ArgumentException("Handler must be provided either a socket or a connection config");
         }
         this.socket = this.connectionConfig.GetSocket();
     }
     this.marshaller    = marshaller ?? this.GetDefaultMarshaller();
     this.buffer        = new byte[this.socket.ReceiveBufferSize];
     this.inboundString = new StringBuilder();
 }
 public AuthConnectionHandler(BaseConfigModel configModel, TAuthIdentity authIdentity)
     : this(null, null, configModel, authIdentity)
 {
 }
Example #3
0
 public BaseHandler(BaseConfigModel connectionConfig)
     : this(null, connectionConfig)
 {
 }