Commit a07ba048 authored by duwei's avatar duwei

指标值为空,不置为0

parent 9b2e3b5c
......@@ -1558,9 +1558,9 @@ public class TrendServiceImpl implements TrendService {
Integer delayTime = po.getDelayTime();
vo.setDelayTime(delayTime);
//路口效率指数
vo.setEfficiencyIndex(0.0);
// vo.setEfficiencyIndex(0.0);
//效率评价等级
vo.setEfficiencyEvaluateLevel(0.0);
// vo.setEfficiencyEvaluateLevel(0.0);
Double stopTimes = po.getStopTimes();
vo.setStopTimes(Math.round(stopTimes *100)/100.0);
......@@ -1570,34 +1570,34 @@ public class TrendServiceImpl implements TrendService {
if (po.getSturation() != null) {
vo.setSaturation((double) Math.round(po.getSturation()*100)/100.0);
}else {
vo.setSaturation(0.0);
// vo.setSaturation(0.0);
}
//拥堵指数
vo.setCongestionIndex(0.0);
// vo.setCongestionIndex(0.0);
//溢出指数
vo.setOverflowIndex(po.getEffusionRate());
//失衡指数
vo.setImbalanceIndex(0.0);
//拥堵次数
vo.setCongestionTimes(0);
// vo.setImbalanceIndex(0.0);
// //拥堵次数
// vo.setCongestionTimes(0);
//溢出次数
if (po.getEffusionRate() != null) {
vo.setOverflowTimes(Math.round(po.getEffusionRate() *100)/100.0);
}else {
vo.setOverflowTimes(0);
// vo.setOverflowTimes(0);
}
//失衡次数
vo.setImbalanceTimes(0);
//空放次数
vo.setFreeFlowTimes(0);
// vo.setImbalanceTimes(0);
// //空放次数
// vo.setFreeFlowTimes(0);
//溢流率
if (po.getEffusionRate() != null) {
vo.setOverflowRate(Math.round(po.getEffusionRate()*100)/100.0);
}else {
vo.setOverflowRate(0.0);
// vo.setOverflowRate(0.0);
}
//冲突点
vo.setConflictPoint(0);
// vo.setConflictPoint(0);
Double timeOccupancyDouble = po.getTimeOccupancy();
if (timeOccupancyDouble != null) {
......@@ -1609,15 +1609,15 @@ public class TrendServiceImpl implements TrendService {
vo.setVehicleNumsRatioMean(Math.round(vehicleLengthRatioMean * 100)/100.0);
}
//路口服务水平
vo.setServiceLevel(0);
//路口安全系数
vo.setSafetyCoefficient(0.0);
//安全评价等级
vo.setSafetyEvaluateLevel(0);
//交通事件数
vo.setTrafficEventNum(0);
//交通事故数
vo.setTrafficAccidentNum(0);
// vo.setServiceLevel(0);
// //路口安全系数
// vo.setSafetyCoefficient(0.0);
// //安全评价等级
// vo.setSafetyEvaluateLevel(0);
// //交通事件数
// vo.setTrafficEventNum(0);
// //交通事故数
// vo.setTrafficAccidentNum(0);
//不停车通过率
vo.setNoStopPassRate((double) Math.round(po.getNoStopRate()*100)/100.0);
......@@ -1626,19 +1626,19 @@ public class TrendServiceImpl implements TrendService {
//二次停车通过率
vo.setTwoStopPassRate((double) Math.round(po.getTwoStopRate()*100)/100.0);
//路口未清空率
vo.setCrossNoClearRate(0);
// vo.setCrossNoClearRate(0);
//平均排队长度
if (po.getQueueLength() != null) {
vo.setAvgQueueLength(po.getQueueLength());
}else{
vo.setAvgQueueLength(0.0);
// vo.setAvgQueueLength(0.0);
}
//绿灯有效利用率
vo.setGreenLightEfficiency(0.0);
//行人平均通过时间
vo.setPedAvgPassTime(0.0);
//行人闯红灯率
vo.setPedCrossRedLightRate(0.0);
// vo.setGreenLightEfficiency(0.0);
// //行人平均通过时间
// vo.setPedAvgPassTime(0.0);
// //行人闯红灯率
// vo.setPedCrossRedLightRate(0.0);
vo.setVehheadDist((double) Math.round(po.getVehheadDist()*100)/100.0);
......@@ -1681,14 +1681,14 @@ public class TrendServiceImpl implements TrendService {
//vo.setAllVehiceleFlow(po.getFlow() + po.getNonMotorFlow());
vo.setAllVehiceleFlow(po.getFlow() + 0);//车辆总和
vo.setAllFlow(0 + 0 + po.getFlow());
vo.setPedFlow(0);
vo.setNonMotorFlow(0);//非机动车流量
// vo.setPedFlow(0);
// vo.setNonMotorFlow(0);//非机动车流量
vo.setTrafficFlowA( po.getTrafficFlowA());
vo.setTrafficFlowB( po.getTrafficFlowB());
vo.setTrafficFlowC( po.getTrafficFlowC());
Double speed = po.getSpeed();
vo.setSpeed( Math.round(speed*100)/100.0);
vo.setVehheadDist(0d);//车头间距
// vo.setVehheadDist(0d);//车头间距
Double queueLength = po.getQueueLength();
vo.setQueueLength(Math.round(queueLength *100)/100.0);
Double stopTimes = po.getStopTimes();
......@@ -1696,7 +1696,7 @@ public class TrendServiceImpl implements TrendService {
if (po.getVehheadTime() != null) {
vo.setVehheadTime(Math.round(po.getVehheadTime()*100)/100.0);
}else {
vo.setVehheadTime(0);
// vo.setVehheadTime(0);
}
//----------------------------------------------------------------------------------------------
......@@ -1712,36 +1712,36 @@ public class TrendServiceImpl implements TrendService {
Integer delayTime = po.getDelayTime();
vo.setDelayTime(delayTime);
//路口效率指数
vo.setEfficiencyIndex(0.0);
// vo.setEfficiencyIndex(0.0);
//效率评价等级
vo.setEfficiencyEvaluateLevel(0.0);
// vo.setEfficiencyEvaluateLevel(0.0);
//饱和度
if(po.getSturation() != null) {
//保留小数点后两位
vo.setSaturation(Math.round(po.getSturation() * 100) / 100.0);
}
//拥堵指数
vo.setCongestionIndex(0.0);
// vo.setCongestionIndex(0.0);
//溢出指数
if (po.getEffusionRate() != null) {
vo.setOverflowIndex(po.getEffusionRate());
}else {
vo.setOverflowIndex(0.0);
// vo.setOverflowIndex(0.0);
}
//失衡指数
vo.setImbalanceIndex(0.0);
//拥堵次数
vo.setCongestionTimes(0);
//溢出次数
vo.setOverflowTimes(0);
//失衡次数
vo.setImbalanceTimes(0);
//空放次数
vo.setFreeFlowTimes(0);
//溢流率
vo.setOverflowRate(0.0);
//冲突点
vo.setConflictPoint(0);
// vo.setImbalanceIndex(0.0);
// //拥堵次数
// vo.setCongestionTimes(0);
// //溢出次数
// vo.setOverflowTimes(0);
// //失衡次数
// vo.setImbalanceTimes(0);
// //空放次数
// vo.setFreeFlowTimes(0);
// //溢流率
// vo.setOverflowRate(0.0);
// //冲突点
// vo.setConflictPoint(0);
Double timeOccupancyDouble = po.getTimeOccupancy();
if (timeOccupancyDouble != null) {
......@@ -1753,43 +1753,43 @@ public class TrendServiceImpl implements TrendService {
vo.setVehicleNumsRatioMean((int) Math.round(0 * 100));
// }
//路口服务水平
vo.setServiceLevel(0);
//路口安全系数
vo.setSafetyCoefficient(0.0);
//安全评价等级
vo.setSafetyEvaluateLevel(0);
//交通事件数
vo.setTrafficEventNum(0);
//交通事故数
vo.setTrafficAccidentNum(0);
// vo.setServiceLevel(0);
// //路口安全系数
// vo.setSafetyCoefficient(0.0);
// //安全评价等级
// vo.setSafetyEvaluateLevel(0);
// //交通事件数
// vo.setTrafficEventNum(0);
// //交通事故数
// vo.setTrafficAccidentNum(0);
//不停车通过率
if (po.getNoStopRate() != null) {
vo.setNoStopPassRate(Math.round(po.getNoStopRate() * 100) / 100.0);
}else {
vo.setNoStopPassRate(0);
// vo.setNoStopPassRate(0);
}
//一次停车通过率
if (po.getOneStopRate() != null) {
vo.setOneStopPassRate(Math.round(po.getOneStopRate() * 100) / 100.0);
}else {
vo.setOneStopPassRate(0);
// vo.setOneStopPassRate(0);
}
//二次停车通过率
if (po.getTwoStopRate() != null) {
vo.setTwoStopPassRate(Math.round(po.getTwoStopRate() * 100) / 100.0);
}else {
vo.setTwoStopPassRate(0);
// vo.setTwoStopPassRate(0);
}
//路口未清空率
vo.setCrossNoClearRate(0);
//平均排队长度
vo.setAvgQueueLength(0.0);
//绿灯有效利用率
vo.setGreenLightEfficiency(0.0);
//行人平均通过时间
vo.setPedAvgPassTime(0.0);
//行人闯红灯率
vo.setPedCrossRedLightRate(0.0);
// vo.setCrossNoClearRate(0);
// //平均排队长度
// vo.setAvgQueueLength(0.0);
// //绿灯有效利用率
// vo.setGreenLightEfficiency(0.0);
// //行人平均通过时间
// vo.setPedAvgPassTime(0.0);
// //行人闯红灯率
// vo.setPedCrossRedLightRate(0.0);
// vo.setV85(Math.round(po.getV85() * 100) / 100);
//
......@@ -1830,20 +1830,20 @@ public class TrendServiceImpl implements TrendService {
vo.setAllFlow(0 + 0 + po.getFlow());//总流量
//vo.setAllVehiceleFlow(po.getFlow() + po.getNonMotorFlow());
vo.setAllVehiceleFlow(po.getFlow() + 0);//车辆总和
vo.setPedFlow(0);
// vo.setPedFlow(0);
if (po.getNonMotorFlow() != null) {
vo.setNonMotorFlow(Math.round(po.getNonMotorFlow() *100)/100.0);//非机动车流量
}else {
vo.setNonMotorFlow(0);
// vo.setNonMotorFlow(0);
}
vo.setTrafficFlowA((int) po.getTrafficFlowA());
vo.setTrafficFlowB((int) po.getTrafficFlowB());
vo.setTrafficFlowC((int) po.getTrafficFlowC());
Double speed = po.getSpeed();
vo.setSpeed(Math.round(speed *100)/100.0);
vo.setVehheadDist(0d);//车头间距
Double vehheadTime = 0d;
vo.setVehheadTime(Math.round(vehheadTime *100)/100.0);//车头时距
// vo.setVehheadDist(0d);//车头间距
// Double vehheadTime = 0d;
// vo.setVehheadTime(Math.round(vehheadTime *100)/100.0);//车头时距
Double queueLength = po.getQueueLength();
vo.setQueueLength(Math.round(queueLength*100)/100.0);
Double stopTimes = po.getStopTimes();//停车次数
......@@ -1862,95 +1862,95 @@ public class TrendServiceImpl implements TrendService {
Integer delayTime = po.getDelayTime();
vo.setDelayTime(delayTime);
//路口效率指数
vo.setEfficiencyIndex(0.0);
// vo.setEfficiencyIndex(0.0);
//效率评价等级
vo.setEfficiencyEvaluateLevel(0.0);
// vo.setEfficiencyEvaluateLevel(0.0);
//饱和度
if(po.getSturation() != null) {
vo.setSaturation(Math.round(po.getSturation()*100)/100.0);
}else {
vo.setSaturation(0.0);
// vo.setSaturation(0.0);
}
//拥堵指数
if(po.getEffusionRate() != null) {
vo.setCongestionIndex(Math.round(po.getEffusionRate()*100)/100.0);
}else {
vo.setCongestionIndex(0.0);
// vo.setCongestionIndex(0.0);
}
//溢出指数
if (po.getEffusionRate() != null) {
vo.setOverflowIndex(po.getEffusionRate());
}
//失衡指数
vo.setImbalanceIndex(0.0);
//拥堵次数
vo.setCongestionTimes(0);
//溢出次数
vo.setOverflowTimes(0);
//失衡次数
vo.setImbalanceTimes(0);
//空放次数
vo.setFreeFlowTimes(0);
// vo.setImbalanceIndex(0.0);
// //拥堵次数
// vo.setCongestionTimes(0);
// //溢出次数
// vo.setOverflowTimes(0);
// //失衡次数
// vo.setImbalanceTimes(0);
// //空放次数
// vo.setFreeFlowTimes(0);
//溢流率
if (po.getEffusionRate() != null) {
vo.setOverflowRate(po.getEffusionRate());
}
//冲突点
vo.setConflictPoint(0);
// vo.setConflictPoint(0);
Double timeOccupancyDouble = po.getTimeOccupancy();
if (timeOccupancyDouble != null) {
vo.setTimeOccupancy(Math.round(timeOccupancyDouble * 100)/100.0);
}else {
vo.setTimeOccupancy(0);
// vo.setTimeOccupancy(0);
}
// Double vehicleLengthRatioMean = po.getVehicleLengthRatioMean();
// if (vehicleLengthRatioMean != null) {
vo.setVehicleNumsRatioMean((int) Math.round(0 * 100));
// vo.setVehicleNumsRatioMean((int) Math.round(0 * 100));
// }
//路口服务水平
vo.setServiceLevel(0);
//路口安全系数
vo.setSafetyCoefficient(0.0);
//安全评价等级
vo.setSafetyEvaluateLevel(0);
//交通事件数
vo.setTrafficEventNum(0);
//交通事故数
vo.setTrafficAccidentNum(0);
// vo.setServiceLevel(0);
// //路口安全系数
// vo.setSafetyCoefficient(0.0);
// //安全评价等级
// vo.setSafetyEvaluateLevel(0);
// //交通事件数
// vo.setTrafficEventNum(0);
// //交通事故数
// vo.setTrafficAccidentNum(0);
//不停车通过率
if (po.getNoStopRate() != null) {
vo.setNoStopPassRate(Math.round(po.getNoStopRate()*100)/100.0);
}else {
vo.setNoStopPassRate(0);
// vo.setNoStopPassRate(0);
}
//一次停车通过率
if (po.getOneStopRate() != null) {
vo.setOneStopPassRate(Math.round(po.getOneStopRate()*100)/100.0);
}else {
vo.setOneStopPassRate(0);
// vo.setOneStopPassRate(0);
}
//二次停车通过率
if (po.getTwoStopRate() != null) {
vo.setTwoStopPassRate(Math.round(po.getTwoStopRate()*100)/100.0);
}else {
vo.setTwoStopPassRate(0);
// vo.setTwoStopPassRate(0);
}
//路口未清空率
vo.setCrossNoClearRate(0);
// vo.setCrossNoClearRate(0);
//平均排队长度
if (po.getQueueLength() != null) {
vo.setAvgQueueLength(Math.round(po.getQueueLength()*100)/100.0);
}else {
vo.setAvgQueueLength(0.0);
// vo.setAvgQueueLength(0.0);
}
//绿灯有效利用率
vo.setGreenLightEfficiency(0.0);
//行人平均通过时间
vo.setPedAvgPassTime(0.0);
//行人闯红灯率
vo.setPedCrossRedLightRate(0.0);
// vo.setGreenLightEfficiency(0.0);
// //行人平均通过时间
// vo.setPedAvgPassTime(0.0);
// //行人闯红灯率
// vo.setPedCrossRedLightRate(0.0);
// vo.setV85(Math.round(po.getV85() * 100) / 100);
// vo.setAllFlow(pedFlow + po.getNonMotorFlow() + po.getFlow());
//
......@@ -1985,14 +1985,14 @@ public class TrendServiceImpl implements TrendService {
//行人流量 + 非机动车流量 + 流量
vo.setAllFlow(0 + po.getNonMotorFlow() + po.getFlow());
vo.setAllVehiceleFlow(po.getFlow() + po.getNonMotorFlow());
vo.setPedFlow(0);
// vo.setPedFlow(0);
vo.setNonMotorFlow(po.getNonMotorFlow());
vo.setTrafficFlowA( po.getTrafficFlowA());
vo.setTrafficFlowB( po.getTrafficFlowB());
vo.setTrafficFlowC( po.getTrafficFlowC());
Double speed = po.getSpeed();
vo.setSpeed(Math.round(speed * 100)/ 100.0);
vo.setVehheadDist(0d);//车头间距
// vo.setVehheadDist(0d);//车头间距
Double vehheadTime = 0d;
vo.setVehheadTime(Math.round(vehheadTime*100)/100.0);//车头时距
Double queueLength = po.getQueueLength();
......@@ -2001,7 +2001,7 @@ public class TrendServiceImpl implements TrendService {
if (stopTimes != null) {
vo.setStopTimes(Math.round(stopTimes *100)/100.0);//Math.round(0.01d * 100) / 100.0
}else {
vo.setStopTimes(0);
// vo.setStopTimes(0);
}
//----------------------------------------------------------------------------------------------
......@@ -2019,105 +2019,105 @@ public class TrendServiceImpl implements TrendService {
Integer delayTime = po.getDelayTime();
vo.setDelayTime(delayTime);
//路口效率指数
vo.setEfficiencyIndex(0.0);
// vo.setEfficiencyIndex(0.0);
//效率评价等级
vo.setEfficiencyEvaluateLevel(0.0);
// vo.setEfficiencyEvaluateLevel(0.0);
//饱和度
if (po.getSturation() != null) {
vo.setSaturation(Math.round(po.getSturation() *100)/100.0);//Math.round(0.01d * 100) / 100.0
}else {
vo.setSaturation(0.0);
// vo.setSaturation(0.0);
}
//拥堵指数
if (po.getCongestionIndex() != null) {
vo.setCongestionIndex(Math.round(po.getCongestionIndex()*100)/100.0);
}else {
vo.setCongestionIndex(0.0);
// vo.setCongestionIndex(0.0);
}
//溢出指数
if (po.getSpilloverIndex() != null) {
vo.setOverflowIndex(Math.round(po.getSpilloverIndex()*100)/100.0);
}else {
vo.setOverflowIndex(0.0);
// vo.setOverflowIndex(0.0);
}
//失衡指数
if (po.getUnbalanceIndex() != null) {
vo.setImbalanceIndex(Math.round(po.getUnbalanceIndex()*100)/100.0);
}else {
vo.setImbalanceIndex(0.0);
// vo.setImbalanceIndex(0.0);
}
//拥堵次数
vo.setCongestionTimes(0);
// vo.setCongestionTimes(0);
//溢出次数
vo.setOverflowTimes(0);
// vo.setOverflowTimes(0);
//失衡次数
vo.setImbalanceTimes(0);
// vo.setImbalanceTimes(0);
//空放次数
vo.setFreeFlowTimes(0);
// vo.setFreeFlowTimes(0);
//溢流率
vo.setOverflowRate(0.0);
// vo.setOverflowRate(0.0);
//冲突点
vo.setConflictPoint(0);
// vo.setConflictPoint(0);
Double timeOccupancyDouble = po.getTimeOccupancy();
if (timeOccupancyDouble != null) {
vo.setTimeOccupancy(Math.round(timeOccupancyDouble * 100) /100.0);//Math.round(0.01d * 100) / 100.0
}else {
vo.setTimeOccupancy(0);
// vo.setTimeOccupancy(0);
}
Double vehicleLengthRatioMean = po.getVehicleLengthRatioMean();
if (vehicleLengthRatioMean != null) {
vo.setVehicleNumsRatioMean(Math.round(vehicleLengthRatioMean * 100) /100.0);
}else {
vo.setVehicleNumsRatioMean(0);
// vo.setVehicleNumsRatioMean(0);
}
//路口服务水平
vo.setServiceLevel(0);
// vo.setServiceLevel(0);
//路口安全系数
vo.setSafetyCoefficient(0.0);
// vo.setSafetyCoefficient(0.0);
//安全评价等级
vo.setSafetyEvaluateLevel(0);
// vo.setSafetyEvaluateLevel(0);
//交通事件数
vo.setTrafficEventNum(0);
// vo.setTrafficEventNum(0);
//交通事故数
vo.setTrafficAccidentNum(0);
// vo.setTrafficAccidentNum(0);
//不停车通过率
if (po.getNoStopRate() != null) {
vo.setNoStopPassRate(Math.round(po.getNoStopRate() *100) / 100.0d);//Math.round(0.01d * 100) / 100.0
}else {
vo.setNoStopPassRate(0);
// vo.setNoStopPassRate(0);
}
//一次停车通过率
if (po.getOneStopRate() != null) {
vo.setOneStopPassRate( Math.round(po.getOneStopRate() *100)/ 100.0);//Math.round(0.01d * 100) / 100.0
}else {
vo.setOneStopPassRate(0);
// vo.setOneStopPassRate(0);
}
//二次停车通过率
if (po.getTwoStopRate() != null) {
vo.setTwoStopPassRate(Math.round(po.getTwoStopRate() *100)/100.0);//Math.round(0.01d * 100) / 100.0
}else {
vo.setTwoStopPassRate(0);
// vo.setTwoStopPassRate(0);
}
//三次停车通过率
if (po.getThreeStopRate() != null) {
vo.setThreeStopRate(Math.round(po.getThreeStopRate()*100)/100.0);
}else {
vo.setThreeStopRate(0.0);
// vo.setThreeStopRate(0.0);
}
//路口未清空率
vo.setCrossNoClearRate(0);
// vo.setCrossNoClearRate(0);
//平均排队长度
vo.setAvgQueueLength(0.0);
// vo.setAvgQueueLength(0.0);
//绿灯有效利用率
vo.setGreenLightEfficiency(0.0);
// vo.setGreenLightEfficiency(0.0);
//行人平均通过时间
vo.setPedAvgPassTime(0.0);
// vo.setPedAvgPassTime(0.0);
//行人闯红灯率
vo.setPedCrossRedLightRate(0.0);
// vo.setPedCrossRedLightRate(0.0);
// vo.setVehheadDist(po.getVehheadDist());
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment