package incheon.cmm.g2f.layer.vo;

import lombok.Getter;
import lombok.Setter;
import lombok.NoArgsConstructor;
import io.swagger.v3.oas.annotations.media.Schema;

/**
 * 레이어 편집 결과 VO
 */
@Getter
@Setter
@Schema(description = "레이어 편집 결과")
public class LayerEditResultVO {
    
    @Schema(description = "편집된 레이어 ID", example = "64")
    private String layerId;
    
    @Schema(description = "처리 결과 통계")
    private ProcessedCount processed;  // 간단한 처리 개수
    
    public LayerEditResultVO() {
        this.processed = new ProcessedCount();
    }
    
    // 편의 메소드들
    public void addAddedCount(int count) {
        this.processed.added += count;
    }
    
    public void addModifiedCount(int count) {
        this.processed.modified += count;
    }
    
    public void addDeletedCount(int count) {
        this.processed.deleted += count;
    }
    
    /**
     * 처리 결과 카운트
     */
    @Getter
    @Setter
    @NoArgsConstructor
    @Schema(description = "처리 결과 통계")
    public static class ProcessedCount {
        @Schema(description = "추가된 피처 수", example = "1")
        private int added = 0;
        
        @Schema(description = "수정된 피처 수", example = "1")
        private int modified = 0;
        
        @Schema(description = "삭제된 피처 수", example = "2")
        private int deleted = 0;
    }
}