package com.cd.detection.domain.zoo.dto;

import java.time.LocalDate;
import java.util.List;
import lombok.AllArgsConstructor;
import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.Setter;
import org.springframework.data.domain.PageRequest;
import org.springframework.data.domain.Pageable;

public class ZooDto {

  @Getter
  @Setter
  @NoArgsConstructor
  @AllArgsConstructor
  public static class SearchListRequest {
    // 페이징 파라미터
    private int page = 0;
    private int size = 20;

    public Pageable toPageable() {
      return PageRequest.of(page, size);
    }
  }

  @Getter
  @Setter
  public static class AddRequest {

    private String zooName;
    private String description;
  }

  @Getter
  @Setter
  public static class ModifyRequest {

    private Long id;
    private String zooName;
    private String description;
    private Boolean useYn;
    private Boolean delYn;
  }

  @Getter
  @Setter
  public static class ZooWithAnimalsRes {

    private Long zooId;          // 동물원 ID
    private String zooName;      // 동물원 이름
    private String description;  // 설명

    private List<AnimalRes> animals;
  }

  @Getter
  @Setter
  public static class AnimalRes {
    private Long animalId;
    private String animalName;
    private String species;
    private Integer age;
  }
}
