[清扫车]修复偶现java.lang.RuntimeException: Parcel: unable to marshal value com.mogo.och.sweeper.bean.SweeperRoutePlanningUpdateReqBean$Result@b444642问题

This commit is contained in:
bxb
2023-03-27 20:32:00 +08:00
parent 9c29f1cf0e
commit ec6f7441d5
2 changed files with 4 additions and 15 deletions

View File

@@ -1,6 +1,7 @@
package com.mogo.och.sweeper.bean;
import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;
/**
@@ -13,15 +14,15 @@ public class SweeperRoutePlanningUpdateReqBean implements Serializable {
public int lineId;
public int startSiteId;
public int endSiteId;
public List<Result> points;
public ArrayList<Result> points;
public static class Result {
public static class Result implements Serializable{
public Double latitude;
public Double longitude;
}
public SweeperRoutePlanningUpdateReqBean(String sn, int lineId, int startSiteId
, int endSiteId, List<Result> points) {
, int endSiteId, ArrayList<Result> points) {
this.sn = sn;
this.lineId = lineId;
this.startSiteId = startSiteId;

View File

@@ -302,10 +302,6 @@ public class SweeperTaskModel {
@Override
public void onChassisLocationGCJ02(@Nullable MogoLocation gnssInfo) {
if (null == gnssInfo) return;
Log.d(M_SWEEPER + TAG, "高德定位到站mLongitude = " + gnssInfo.getLongitude()
+ ", mLatitude=" + gnssInfo.getLatitude() + ", mSubTaskType=" + mSubTaskType + ", mIsSubTaskWorking=" + mIsSubTaskWorking
+ ", isAutopilotSubTaskArriveEndSite=" + isAutopilotSubTaskArriveEndSite
);
CallerLogger.INSTANCE.e(M_SWEEPER + TAG, "高德定位到站mLongitude = " + gnssInfo.getLongitude()
+ ", mLatitude=" + gnssInfo.getLatitude() + ", mSubTaskType=" + mSubTaskType +", mIsSubTaskWorking=" + mIsSubTaskWorking
+ ", isAutopilotSubTaskArriveEndSite=" + isAutopilotSubTaskArriveEndSite
@@ -349,7 +345,6 @@ public class SweeperTaskModel {
//根据围栏判断,是否到达子任务终点
private void judgeArrivedStation(MogoLocation location) {
if (mCurrentSubTaskDetail == null) {
Log.d(TAG, "行程日志-judgeArrivedStation() mCurrentSubTaskDetail is null");
CallerLogger.INSTANCE.d(TAG, "行程日志-judgeArrivedStation() mCurrentSubTaskDetail is null");
return;
}
@@ -361,8 +356,6 @@ public class SweeperTaskModel {
if (distance <= SweeperConst.ARRIVE_AT_END_STATION_DISTANCE) {
CallerLogger.INSTANCE.d(M_SWEEPER + TAG, "行程日志-judgeArrivedStation() distance = " + distance
+ " to " + mCurrentSubTaskDetail.getEndSiteName());
Log.d(TAG, "行程日志-judgeArrivedStation() distance = " + distance
+ " to " + mCurrentSubTaskDetail.getEndSiteName());
isAutopilotSubTaskArriveEndSite = true;
//到达子任务终点 结束子任务
subTaskEnd(mIsFirstSubtask, mIsLastSubtask, mSubTaskId); //无自动驾驶到终点信息传null
@@ -446,8 +439,6 @@ public class SweeperTaskModel {
//MAP 280 每隔100ms左右返回一次到站 导致在到达中间站后再次滑动出发后会有时间差,收到一次到站,出现问题
//此处比对 自驾告诉的子任务终点坐标和本地应到子任务终点坐标, 一致时才表示子任务完成
if (data != null && data.getEndLocation() != null && mCurrentSubTaskDetail != null) {
Log.d(M_SWEEPER + TAG, "MAP到站通知" + mCurrentSubTaskDetail.getEndSiteName() + " 经度:"
+ data.getEndLocation().getLongitude() + " 纬度:" + data.getEndLocation().getLatitude());
CallerLogger.INSTANCE.d(M_SWEEPER + TAG, "MAP到站通知" + mCurrentSubTaskDetail.getEndSiteName() + " 经度:"
+ data.getEndLocation().getLongitude() + " 纬度:" + data.getEndLocation().getLatitude());
String latitude = NumberFormatUtil.cutOutNumber(data.getEndLocation().getLatitude(), 5); //wgs
@@ -459,8 +450,6 @@ public class SweeperTaskModel {
return;
}
}
Log.d(M_SWEEPER + TAG, "MAP到站通知mSubTaskType=" + mSubTaskType + " isAutopilotSubTaskArriveEndSite="
+ isAutopilotSubTaskArriveEndSite + " mSubTaskId=" + mSubTaskId);
CallerLogger.INSTANCE.d(M_SWEEPER + TAG, "MAP到站通知mSubTaskType=" + mSubTaskType + " isAutopilotSubTaskArriveEndSite="
+ isAutopilotSubTaskArriveEndSite + " mSubTaskId=" + mSubTaskId);
if (SubTaskTypeEnum.MANUAL_DRIVING_SUBTYPE.getCode() == mSubTaskType) {//人工驾驶子任务需要手动跳过,不能自动结束
@@ -664,7 +653,6 @@ public class SweeperTaskModel {
@Override
public void onSuccess(BaseResponse<SweeperSubTaskDetailBean> data) {
CallerLogger.INSTANCE.d(M_SWEEPER + TAG, "getSubTaskDetail" + GsonUtil.jsonFromObject(data));
Log.d(M_SWEEPER + TAG, "getSubTaskDetail" + GsonUtil.jsonFromObject(data));
if (data != null) {
mCurrentSubTaskDetail = data.getData();
if (mCurrentSubTaskDetail != null) {