提交可正常处理acft消息的代码

This commit is contained in:
zhouxiunai
2018-12-05 18:05:50 +08:00
parent 1b1207b07a
commit e19a281cb6
23 changed files with 567 additions and 34 deletions
@@ -2,7 +2,6 @@ package com.gzzn.omms.msgexchangeapi.msghandler.flop;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import com.gzzn.omms.msgexchangeapi.entity.msg.flop.acft.ACFTMsg;
import com.gzzn.omms.msgexchangeapi.entity.msg.schd.dnld.FLTR;
@@ -10,22 +9,20 @@ import com.gzzn.omms.msgexchangeapi.msghandler.HandlerResult;
import com.gzzn.omms.msgexchangeapi.msghandler.IBaseHandler;
import com.gzzn.omms.msgexchangeapi.service.IExchangeService;
import com.gzzn.omms.msgexchangeapi.service.flightInfo.IFlightInfoService;
import com.gzzn.omms.msgexchangeapi.utils.SpringUtil;
public class ACFTHandler implements IBaseHandler {
private static Logger logger = LoggerFactory.getLogger(ACFTHandler.class);
@Autowired
IExchangeService exchangeService;
@Autowired
IFlightInfoService flightInfoService;
/**
* 处理航班消息,更新航班动态信息
*/
@Override
public HandlerResult run(String msg) {
IExchangeService exchangeService = (IExchangeService) SpringUtil.getBean("exchangeService");
IFlightInfoService flightInfoService = (IFlightInfoService) SpringUtil.getBean("flightInfoService");
ACFTMsg acftMsg = exchangeService.xmlstrToObject(msg, ACFTMsg.class);
FLTR fltr = flightInfoService.getByFlid(acftMsg.getFLOP().getFLID());
if(null != fltr)