package cn.wise.sc.energy.power.plant.business.bean;

import cn.wise.sc.energy.power.plant.common.core.exception.ResponseEnum;
import lombok.Data;

/**
 * @description: 时间查询对象
 * @author: qh
 * @create: 2020-05-20 16:18
 */
public class TimeModelQuery {

  public long getStart() {
    return start;
  }

  public void setStart(long start) {
    if (end != null && end != 0L && start >= end) {
      ResponseEnum.BAD_TIME.assertNotNull(null);
    }
    this.start = start;
  }

  public long getEnd() {
    return end;
  }

  public void setEnd(long end) {
    if (start != null && start != 0L && start >= end) {
      ResponseEnum.BAD_TIME.assertNotNull(null);
    }
    this.end = end;
  }

  private Long start;

  private Long end;

}
