| | |
| | | * 解析报文 |
| | | */ |
| | | public UPExgMsgRealLocation decode(UPExgMsg exgMsg) { |
| | | byte[] data = exgMsg.getData(); |
| | | ByteBuf byteBuf = Unpooled.wrappedBuffer(data); |
| | | this.vehicleNo = exgMsg.getVehicleNo(); |
| | | this.vehicleColor = exgMsg.getVehicleColor(); |
| | | this.dataType = exgMsg.getDataType(); |
| | | this.dataLength = exgMsg.getDataLength(); |
| | | this.gnssData = new GnssData().decode(byteBuf); |
| | | try { |
| | | byte[] data = exgMsg.getData(); |
| | | ByteBuf byteBuf = Unpooled.wrappedBuffer(data); |
| | | this.vehicleNo = exgMsg.getVehicleNo(); |
| | | this.vehicleColor = exgMsg.getVehicleColor(); |
| | | this.dataType = exgMsg.getDataType(); |
| | | this.dataLength = exgMsg.getDataLength(); |
| | | this.gnssData = new GnssData().decode(byteBuf); |
| | | }catch (Exception e){ |
| | | e.printStackTrace(); |
| | | } |
| | | return this; |
| | | } |
| | | } |