package com.usky.rule.vo;

import com.fasterxml.jackson.annotation.JsonProperty;

public class TimeRange {
    @JsonProperty("type")
    private String type;
    @JsonProperty("start")
    private Integer start;
    @JsonProperty("end")
    private Integer end;

    public TimeRange() {
    }

    public String getType() {
        return this.type;
    }

    public Integer getStart() {
        return this.start;
    }

    public Integer getEnd() {
        return this.end;
    }

    @JsonProperty("type")
    public void setType(final String type) {
        this.type = type;
    }

    @JsonProperty("start")
    public void setStart(final Integer start) {
        this.start = start;
    }

    @JsonProperty("end")
    public void setEnd(final Integer end) {
        this.end = end;
    }

    public boolean equals(final Object o) {
        if (o == this) {
            return true;
        } else if (!(o instanceof TimeRange)) {
            return false;
        } else {
            TimeRange other = (TimeRange)o;
            if (!other.canEqual(this)) {
                return false;
            } else {
                Object this$start = this.getStart();
                Object other$start = other.getStart();
                if (this$start == null) {
                    if (other$start != null) {
                        return false;
                    }
                } else if (!this$start.equals(other$start)) {
                    return false;
                }

                Object this$end = this.getEnd();
                Object other$end = other.getEnd();
                if (this$end == null) {
                    if (other$end != null) {
                        return false;
                    }
                } else if (!this$end.equals(other$end)) {
                    return false;
                }

                Object this$type = this.getType();
                Object other$type = other.getType();
                if (this$type == null) {
                    if (other$type != null) {
                        return false;
                    }
                } else if (!this$type.equals(other$type)) {
                    return false;
                }

                return true;
            }
        }
    }

    protected boolean canEqual(final Object other) {
        return other instanceof TimeRange;
    }

    public int hashCode() {
        int PRIME = 59;
        int result = 1;
        Object $start = this.getStart();
        result = result * 59 + ($start == null ? 43 : $start.hashCode());
        Object $end = this.getEnd();
        result = result * 59 + ($end == null ? 43 : $end.hashCode());
        Object $type = this.getType();
        result = result * 59 + ($type == null ? 43 : $type.hashCode());
        return result;
    }

    public String toString() {
        return "TimeRange(type=" + this.getType() + ", start=" + this.getStart() + ", end=" + this.getEnd() + ")";
    }
}