package com.kamco.cd.kamcoback.postgres.entity;

import jakarta.persistence.Column;
import jakarta.persistence.Entity;
import jakarta.persistence.GeneratedValue;
import jakarta.persistence.GenerationType;
import jakarta.persistence.Id;
import jakarta.persistence.SequenceGenerator;
import jakarta.persistence.Table;
import jakarta.validation.constraints.Size;
import java.time.ZonedDateTime;
import lombok.Getter;
import lombok.Setter;
import org.locationtech.jts.geom.Geometry;

@Getter
@Setter
@Entity
@Table(name = "tb_map_sheet_learn_data_geom")
public class MapSheetLearnDataGeomEntity {

  @Id
  @GeneratedValue(
      strategy = GenerationType.SEQUENCE,
      generator = "tb_map_sheet_learn_data_geom_id_gen")
  @SequenceGenerator(
      name = "tb_map_sheet_learn_data_geom_id_gen",
      sequenceName = "tb_map_sheet_learn_data_geom_geom_uid",
      allocationSize = 1)
  @Column(name = "geo_uid", nullable = false)
  private Long id;

  @Column(name = "after_yyyy")
  private Integer afterYyyy;

  @Column(name = "area")
  private Double area;

  @Column(name = "before_yyyy")
  private Integer beforeYyyy;

  @Column(name = "cd_prob")
  private Double cdProb;

  @Size(max = 100)
  @Column(name = "class_after_name", length = 100)
  private String classAfterName;

  @Column(name = "class_after_prob")
  private Double classAfterProb;

  @Size(max = 100)
  @Column(name = "class_before_name", length = 100)
  private String classBeforeName;

  @Column(name = "class_before_prob")
  private Double classBeforeProb;

  @Column(name = "created_dttm", columnDefinition = "TIMESTAMP WITH TIME ZONE")
  private ZonedDateTime createdDttm;

  @Column(name = "created_uid")
  private Long createdUid;

  private Long dataUid;

  @Size(max = 100)
  @Column(name = "geo_type", length = 100)
  private String geoType;

  @Column(name = "geom")
  private Geometry geom;

  @Column(name = "map_sheet_num")
  private Long mapSheetNum;

  @Column(name = "updated_dttm", columnDefinition = "TIMESTAMP WITH TIME ZONE")
  private ZonedDateTime updatedDttm;

  @Column(name = "updated_uid")
  private Long updatedUid;
}
