FHLResolveImpl.java
1.1 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
package com.tianbo.analysis.service.imp;
import com.tianbo.analysis.dao.OriginmanifestsecondaryMapper;
import com.tianbo.analysis.dao.TBBaseAirportInfoDao;
import com.tianbo.analysis.model.Originmanifestsecondary;
import com.tianbo.analysis.model.ResultJson;
import com.tianbo.analysis.service.FHLResolve;
import org.springframework.stereotype.Service;
import javax.annotation.Resource;
@Service("nmmsV1FHLResolve")
public class FHLResolveImpl implements FHLResolve {
@Resource
TBBaseAirportInfoDao airportInfoDao;
@Resource
OriginmanifestsecondaryMapper mapper;
@Override
public ResultJson resolve(Originmanifestsecondary fhl) {
ResultJson resultJson = new ResultJson();
try{
fhl.textToStringList();
if(fhl.startParse()){
resultJson.setMsg("解析报文成功");
resultJson.setCode("200");
}
}catch (Exception e){
e.printStackTrace();
resultJson.setMsg("解析报文失败");
resultJson.setCode("400");
resultJson.setError(e.toString());
}
return resultJson;
}
}