Example #1
0
 /// <summary>
 ///  初始化各种处理器
 /// </summary>
 /// <param name="factory">Session工厂</param>
 /// <param name="filter">连接过滤器</param>
 /// <param name="handshake">握手处理器</param>
 public AsyncTcpListener(ISessionFactory factory, ISocketFilter filter, IHandshake handshake)
 {
     m_sessionFactory = factory;
     m_filter = filter;
     m_handshake = handshake;
     if (m_filter != null && m_filter.IdleMilliseconds > 0)
     {
         m_queue = new System.Collections.Concurrent.ConcurrentQueue<StateObject>();
     }
 }
Example #2
0
 /// <summary>
 ///  初始化各种处理器
 /// </summary>
 /// <param name="factory">Session工厂</param>
 /// <param name="filter">连接过滤器</param>
 /// <param name="handshake">握手处理器</param>
 public AmfServer(ISessionFactory factory, ISocketFilter filter, IHandshake handshake)
     : base(factory, filter, handshake)
 {
 }
Example #3
0
 /// <summary>
 ///  初始化各种处理器
 /// </summary>
 /// <param name="factory">Session工厂</param>
 /// <param name="filter">连接过滤器</param>
 /// <param name="handshake">握手处理器</param>
 public GMService(ISessionFactory factory, ISocketFilter filter, IHandshake handshake)
     : base(factory, filter, handshake)
 {
 }
Example #4
0
 public SocketSpreader(Action <string> spreadCallback, ISocketFilter handshakeContext)
 {
     this.SpreadCallback = spreadCallback;
     this.Handshake      = handshakeContext;
 }