| | |
| | | * @date 2023-06-18 |
| | | */ |
| | | public class Report { |
| | | @ApiModelProperty(value = "溯源ID") |
| | | private String id; |
| | | |
| | | @ApiModelProperty(value = "点位名称") |
| | | private String name; |
| | | |
| | |
| | | public Report() { |
| | | } |
| | | |
| | | public Report(String name, double lon, double lat, double val, String time, double speed, String dir, double maxVal, double dis, String maxDir, int isSame) { |
| | | public Report(String id, String name, double lon, double lat, double val, String time, double speed, String dir, double maxVal, double dis, String maxDir, int isSame) { |
| | | this.id = id; |
| | | this.name = name; |
| | | this.lon = lon; |
| | | this.lat = lat; |
| | |
| | | String maxDir = CalculateUtils.getDir(direction2); // CalculateUtils.getDir(angle); |
| | | int isSame = (Math.abs(direction1 - direction2) <= 45 && Math.abs(speed1 - speed2) <= 0.5) ? 1 : 0; |
| | | |
| | | return new Report(wd.getLocationName(), c1.getX(), c1.getY(), wd.getValue(), time, |
| | | return new Report(wd.getSuYuanId(), wd.getLocationName(), c1.getX(), c1.getY(), wd.getValue(), time, |
| | | speed1, dir, maxVal, dis1, maxDir, isSame); |
| | | } |
| | | |
| | | public String getId() { |
| | | return id; |
| | | } |
| | | |
| | | public void setId(String id) { |
| | | this.id = id; |
| | | } |
| | | |
| | | public String getName() { |
| | | return name; |
| | | } |
| | |
| | | @ApiModelProperty(value = "主键") |
| | | private BigInteger id; |
| | | |
| | | @ApiModelProperty(value = "溯源ID") |
| | | private String suYuanId; |
| | | |
| | | @CsvProperty(index = 0) |
| | | @ApiModelProperty(value = "X") |
| | | private Integer x; |
| | |
| | | this.id = id; |
| | | } |
| | | |
| | | public String getSuYuanId() { |
| | | return x + "_" + y + "_0"; |
| | | } |
| | | |
| | | public Integer getX() { |
| | | return x; |
| | | } |