
package dev.sonpx.loyalty.mcp.reward.model;

import com.fasterxml.jackson.annotation.JsonFormat;
import dev.sonpx.loyalty.mcp.enums.schedule.*;
import jakarta.validation.constraints.Positive;
import java.time.LocalDate;
import java.time.LocalTime;
import java.util.List;
import lombok.Getter;
import lombok.Setter;

@Getter
@Setter
public class CampaignRuleSchedule extends Fw {

    private String ruleId;

    private TriggerMethod triggerMethod;

    private ScheduleRecurrenceType scheduleType;

    private PeriodicType periodicType;

    @Positive
    private Integer repeatPeriod;

    private LocalDate fixedDate;

    private ScheduleMonthType scheduleMonthType;

    private List<DayOfWeek> scheduleDayOfWeek;

    private WeekOfMonth scheduleWeekOfMonth;

    private List<DayOfMonth> scheduleDayOfMonth;

    private Boolean lastDayOfMonth;

    private List<MonthOfYear> scheduleMonthOfYear;

    @JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "HH:mm")
    private LocalTime timeExecution;
}
