Ejemplo n.º 1
0
 public JT809TcpConnectionHandler(
     JT809TcpSessionManager jT809SessionManager,
     ILoggerFactory loggerFactory)
 {
     this.jT809SessionManager = jT809SessionManager;
     logger = loggerFactory.CreateLogger <JT809TcpConnectionHandler>();
 }
Ejemplo n.º 2
0
 public JT809TcpServerHandler(
     ILoggerFactory loggerFactory,
     JT809MsgIdTcpHandlerBase handler,
     JT809TcpAtomicCounterService jT809AtomicCounterService,
     JT809TcpSessionManager jT809SessionManager
     )
 {
     this.handler                   = handler;
     this.jT809SessionManager       = jT809SessionManager;
     this.jT809AtomicCounterService = jT809AtomicCounterService;
     logger = loggerFactory.CreateLogger <JT809TcpServerHandler>();
 }
 /// <summary>
 /// 初始化消息处理业务
 /// </summary>
 protected JT809MsgIdTcpHandlerBase(
     IVerifyCodeGenerator verifyCodeGenerator,
     JT809TcpSessionManager sessionManager)
 {
     this.sessionManager      = sessionManager;
     this.verifyCodeGenerator = verifyCodeGenerator;
     HandlerDict = new Dictionary <JT809BusinessType, Func <JT809Request, JT809Response> >
     {
         { JT809BusinessType.主链路登录请求消息, Msg0x1001 },
         { JT809BusinessType.主链路注销请求消息, Msg0x1003 },
         { JT809BusinessType.主链路连接保持请求消息, Msg0x1005 },
         { JT809BusinessType.主链路动态信息交换消息, Msg0x1200 }
     };
     //SubHandlerDict = new Dictionary<JT809SubBusinessType, Func<JT809Request, JT809Response>>
     //{
     //    {JT809SubBusinessType.实时上传车辆定位信息, Msg0x1200_0x1202},
     //};
 }
Ejemplo n.º 4
0
 public JT809MsgIdDefaultTcpHandler(JT809TcpSessionManager sessionManager) : base(sessionManager)
 {
 }