package com.njcn.harmonic.pojo.param;

import com.njcn.common.pojo.constant.PatternRegex;
import com.njcn.harmonic.constant.HarmonicValidMessage;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import javax.validation.constraints.Max;
import javax.validation.constraints.Min;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Pattern;
import java.io.Serializable;

/**
 * @author hongawen
 * @version 1.0.0
 * @date 2023年07月19日 09:23
 */
@Data
@NoArgsConstructor
@AllArgsConstructor
public class HistoryHarmParam implements Serializable {


    @ApiModelProperty("开始时间")
    @NotBlank(message = HarmonicValidMessage.DATA_NOT_BLANK)
    @Pattern(regexp = PatternRegex.TIME_FORMAT, message = "时间格式错误")
    private String searchBeginTime;

    @ApiModelProperty("结束时间")
    @NotBlank(message = HarmonicValidMessage.DATA_NOT_BLANK)
    @Pattern(regexp = PatternRegex.TIME_FORMAT, message = "时间格式错误")
    private String searchEndTime;

    @NotBlank(message = HarmonicValidMessage.DATA_NOT_BLANK)
    @ApiModelProperty("监测点索引")
    private String lineId;


    @Max(1)
    @Min(0)
    @ApiModelProperty("0-电流 1-电压")
    private  int type;

    @Max(50)
    @Min(2)
    @ApiModelProperty("谐波次数")
    private  Integer time;



}
