package space.nstart.pcp.pcp_types_lib.dto.requests

import jakarta.validation.constraints.DecimalMax
import jakarta.validation.constraints.DecimalMin
import jakarta.validation.constraints.Min
import space.nstart.pcp.pcp_types_lib.dto.requests.slots.SlotCoverageStrategy
import java.time.LocalDateTime

data class ComplexPlanProcessRequestDTO(
    val intervalStart: LocalDateTime,
    val intervalEnd: LocalDateTime,
    val satelliteId: Long? = null,
    val satelliteIds: List<Long> = emptyList(),
    @field:DecimalMin(value = "-90.0", message = "sun must be between -90 and 90 degrees")
    @field:DecimalMax(value = "90.0", message = "sun must be between -90 and 90 degrees")
    val sun: Double? = null,
    val coverageSource: CoverageCalculationSource? = null,
    @field:Min(value = 1, message = "countLat must be greater than 0")
    val countLat: Int? = null,
    @field:Min(value = 1, message = "countLong must be greater than 0")
    val countLong: Int? = null,
    val coverageStrategy: SlotCoverageStrategy? = SlotCoverageStrategy.GREEDY
)

enum class CoverageCalculationSource {
    SLOTS,
    COVERAGE_SCHEME
}
