|
@@ -6,6 +6,9 @@ import com.telpo.dipperposition.enums.DipperReturnValue; |
|
|
import com.telpo.dipperposition.service.IDipperAstPosAsyncTaskService; |
|
|
import com.telpo.dipperposition.service.IDipperAstPosAsyncTaskService; |
|
|
import com.telpo.dipperposition.service.IDipperAstTimeAsyncTaskService; |
|
|
import com.telpo.dipperposition.service.IDipperAstTimeAsyncTaskService; |
|
|
import com.telpo.dipperposition.service.IDipperDataAsyncTaskService; |
|
|
import com.telpo.dipperposition.service.IDipperDataAsyncTaskService; |
|
|
|
|
|
import com.telpo.dipperposition.service.impl.DipperAstPosAsyncTaskServiceImpl; |
|
|
|
|
|
import com.telpo.dipperposition.service.impl.DipperAstTimeAsyncTaskServiceImpl; |
|
|
|
|
|
import com.telpo.dipperposition.service.impl.DipperDataAsyncTaskServiceImpl; |
|
|
import io.netty.buffer.ByteBuf; |
|
|
import io.netty.buffer.ByteBuf; |
|
|
import io.netty.buffer.Unpooled; |
|
|
import io.netty.buffer.Unpooled; |
|
|
import io.netty.channel.socket.SocketChannel; |
|
|
import io.netty.channel.socket.SocketChannel; |
|
@@ -110,6 +113,9 @@ public class NettyServerHandler extends ChannelInboundHandlerAdapter { |
|
|
//if (AST_TIME_CMD.equals(recvmg)) { |
|
|
//if (AST_TIME_CMD.equals(recvmg)) { |
|
|
if (AST_TIME_CMD.equals(msg)) { |
|
|
if (AST_TIME_CMD.equals(msg)) { |
|
|
// 初始时间辅助输入; |
|
|
// 初始时间辅助输入; |
|
|
|
|
|
if (dipperTimeAsyncTaskService == null) { |
|
|
|
|
|
dipperTimeAsyncTaskService = new DipperAstTimeAsyncTaskServiceImpl(); |
|
|
|
|
|
} |
|
|
channelAns = dipperTimeAsyncTaskService.pushAstTime(); |
|
|
channelAns = dipperTimeAsyncTaskService.pushAstTime(); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
@@ -123,6 +129,9 @@ public class NettyServerHandler extends ChannelInboundHandlerAdapter { |
|
|
// positionConfig.getCenterProvince(), |
|
|
// positionConfig.getCenterProvince(), |
|
|
// positionConfig.getIpPositionRequestPath(), |
|
|
// positionConfig.getIpPositionRequestPath(), |
|
|
// positionConfig.getIpPositionRequestKey()); |
|
|
// positionConfig.getIpPositionRequestKey()); |
|
|
|
|
|
if (dipperAstPosAsyncTaskService == null) { |
|
|
|
|
|
dipperAstPosAsyncTaskService = new DipperAstPosAsyncTaskServiceImpl(); |
|
|
|
|
|
} |
|
|
channelAns = dipperAstPosAsyncTaskService.pushAstPos(ipAddress, |
|
|
channelAns = dipperAstPosAsyncTaskService.pushAstPos(ipAddress, |
|
|
"/csv/provinceLonAlt.csv", |
|
|
"/csv/provinceLonAlt.csv", |
|
|
"湖北省", |
|
|
"湖北省", |
|
@@ -134,6 +143,9 @@ public class NettyServerHandler extends ChannelInboundHandlerAdapter { |
|
|
//if (Integer.parseInt(starsAsycServerPort) == channel.localAddress().getPort()) { |
|
|
//if (Integer.parseInt(starsAsycServerPort) == channel.localAddress().getPort()) { |
|
|
//if (AST_POS_CMD.equals(recvmg)) { |
|
|
//if (AST_POS_CMD.equals(recvmg)) { |
|
|
if (AST_POS_CMD.equals(msg)) { |
|
|
if (AST_POS_CMD.equals(msg)) { |
|
|
|
|
|
if (dipperDataAsyncTaskService == null) { |
|
|
|
|
|
dipperDataAsyncTaskService = new DipperDataAsyncTaskServiceImpl(); |
|
|
|
|
|
} |
|
|
channelAns = dipperDataAsyncTaskService.getAstEPH(); |
|
|
channelAns = dipperDataAsyncTaskService.getAstEPH(); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|