변화탐지 polygon, point 4326 으로 변환

This commit is contained in:
2025-12-01 11:06:02 +09:00
parent c40b3015c6
commit cf33d7378f
7 changed files with 136 additions and 51 deletions

View File

@@ -75,7 +75,7 @@ public class ChangeDetectionApiController {
@Operation(summary = "변화탐지 결과 Polygon", description = "변화탐지 결과 Polygon")
@GetMapping("/polygon")
public ApiResponseDto<List<ChangeDetectionDto.PolygonGeometry>> getChangeDetectionPolygonList(
public ApiResponseDto<ChangeDetectionDto.PolygonFeatureList> getChangeDetectionPolygonList(
@Parameter(description = "년도목록 id", example = "1") @RequestParam Long analUid,
@Parameter(description = "도엽번호", example = "34602060") @RequestParam String mapSheetNum) {
return ApiResponseDto.ok(
@@ -84,7 +84,7 @@ public class ChangeDetectionApiController {
@Operation(summary = "변화탐지 결과 Point", description = "변화탐지 결과 Point")
@GetMapping("/point")
public ApiResponseDto<List<ChangeDetectionDto.PointGeometry>> getChangeDetectionPointList(
public ApiResponseDto<List<ChangeDetectionDto.PointFeature>> getChangeDetectionPointList(
@Parameter(description = "년도목록 id", example = "1") @RequestParam Long analUid,
@Parameter(description = "도엽번호", example = "34602060") @RequestParam String mapSheetNum) {
return ApiResponseDto.ok(

View File

@@ -1,6 +1,7 @@
package com.kamco.cd.kamcoback.changedetection.dto;
import io.swagger.v3.oas.annotations.media.Schema;
import java.util.List;
import lombok.AllArgsConstructor;
import lombok.Getter;
import lombok.NoArgsConstructor;
@@ -78,31 +79,54 @@ public class ChangeDetectionDto {
private String alias;
}
@Schema(name = "PolygonGeometry", description = "폴리곤 리턴 객체")
@Schema(name = "PolygonFeatureList", description = "Geometry 리턴 객체")
@Getter
@Setter
@NoArgsConstructor
@AllArgsConstructor
public static class PointGeometry {
private Long geoUid;
private Geometry geometry; // Point 값
public static class PolygonFeatureList {
private String type;
private List<PolygonFeature> features; // Point 값
private String classCd; // after 분류
}
@Schema(name = "PolygonGeometry", description = "폴리곤 리턴 객체")
@Schema(name = "PolygonFeature", description = "Geometry 리턴 객체")
@Getter
@Setter
@NoArgsConstructor
@AllArgsConstructor
public static class PolygonGeometry {
public static class PolygonFeature {
private String type;
private Geometry geometry; // after 분류
private PolygonProperties properties; // Point 값
}
@Schema(name = "PointFeature", description = "Geometry 리턴 객체")
@Getter
@Setter
@NoArgsConstructor
@AllArgsConstructor
public static class PointFeature {
private String type;
private Geometry geometry; // point
private PointProperties properties; // Point 정보
}
@Schema(name = "PointProperties", description = "폴리곤 리턴 객체")
@Getter
@Setter
@NoArgsConstructor
@AllArgsConstructor
public static class PointProperties {
private Long geoUid;
private Geometry geometry; // Polygon 값
private PolygonProperties properties;
private String classCd; // after 분류
}
@Schema(name = "PolygonProperties", description = "폴리곤 정보")
@Getter
@AllArgsConstructor
public static class PolygonProperties {
private Long geoUid;
private Double area; // 면적
private Integer beforeYear; // 기준년도
private Double beforeConfidence; // 기준 신뢰도(확률)

View File

@@ -34,12 +34,12 @@ public class ChangeDetectionService {
return changeDetectionCoreService.getChangeDetectionYearList();
}
public List<ChangeDetectionDto.PolygonGeometry> getChangeDetectionPolygonList(
public ChangeDetectionDto.PolygonFeatureList getChangeDetectionPolygonList(
Long analUid, String mapSheetNum) {
return changeDetectionCoreService.getChangeDetectionPolygonList(analUid, mapSheetNum);
}
public List<ChangeDetectionDto.PointGeometry> getChangeDetectionPointList(
public List<ChangeDetectionDto.PointFeature> getChangeDetectionPointList(
Long analUid, String mapSheetNum) {
return changeDetectionCoreService.getChangeDetectionPointList(analUid, mapSheetNum);
}