ForecastDay.java 4.17 KB
Newer Older
EnesKarakas's avatar
EnesKarakas committed
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
package io.swagger.model;

import java.util.Objects;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonCreator;
import io.swagger.model.Astro;
import io.swagger.model.DayCondition;
import io.swagger.model.HourCondition;
import io.swagger.v3.oas.annotations.media.Schema;
import java.util.ArrayList;
import java.util.List;
import org.springframework.validation.annotation.Validated;
import javax.validation.Valid;
import javax.validation.constraints.*;

/**
 * ForecastDay
 */
@Validated
@javax.annotation.Generated(value = "io.swagger.codegen.v3.generators.java.SpringCodegen", date = "2024-06-06T14:20:51.790816423Z[GMT]")


public class ForecastDay   {
  @JsonProperty("date")
  private String date = null;

  @JsonProperty("date_epoch")
  private Integer dateEpoch = null;

  @JsonProperty("day")
  private DayCondition day = null;

  @JsonProperty("astro")
  private Astro astro = null;

  @JsonProperty("hour")
  @Valid
  private List<HourCondition> hour = null;

  public ForecastDay date(String date) {
    this.date = date;
    return this;
  }

  /**
   * Get date
   * @return date
   **/
  @Schema(description = "")
      @NotNull

    public String getDate() {
    return date;
  }

  public void setDate(String date) {
    this.date = date;
  }

  public ForecastDay dateEpoch(Integer dateEpoch) {
    this.dateEpoch = dateEpoch;
    return this;
  }

  /**
   * Get dateEpoch
   * @return dateEpoch
   **/
  @Schema(description = "")
      @NotNull

    public Integer getDateEpoch() {
    return dateEpoch;
  }

  public void setDateEpoch(Integer dateEpoch) {
    this.dateEpoch = dateEpoch;
  }

  public ForecastDay day(DayCondition day) {
    this.day = day;
    return this;
  }

  /**
   * Get day
   * @return day
   **/
  @Schema(description = "")
      @NotNull

    @Valid
    public DayCondition getDay() {
    return day;
  }

  public void setDay(DayCondition day) {
    this.day = day;
  }

  public ForecastDay astro(Astro astro) {
    this.astro = astro;
    return this;
  }

  /**
   * Get astro
   * @return astro
   **/
  @Schema(description = "")
      @NotNull

    @Valid
    public Astro getAstro() {
    return astro;
  }

  public void setAstro(Astro astro) {
    this.astro = astro;
  }

  public ForecastDay hour(List<HourCondition> hour) {
    this.hour = hour;
    return this;
  }

  public ForecastDay addHourItem(HourCondition hourItem) {
    if (this.hour == null) {
      this.hour = new ArrayList<HourCondition>();
    }
    this.hour.add(hourItem);
    return this;
  }

  /**
   * Get hour
   * @return hour
   **/
  @Schema(description = "")
      @NotNull
    @Valid
    public List<HourCondition> getHour() {
    return hour;
  }

  public void setHour(List<HourCondition> hour) {
    this.hour = hour;
  }


  @Override
  public boolean equals(java.lang.Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    ForecastDay forecastDay = (ForecastDay) o;
    return Objects.equals(this.date, forecastDay.date) &&
        Objects.equals(this.dateEpoch, forecastDay.dateEpoch) &&
        Objects.equals(this.day, forecastDay.day) &&
        Objects.equals(this.astro, forecastDay.astro) &&
        Objects.equals(this.hour, forecastDay.hour);
  }

  @Override
  public int hashCode() {
    return Objects.hash(date, dateEpoch, day, astro, hour);
  }

  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class ForecastDay {\n");
    
    sb.append("    date: ").append(toIndentedString(date)).append("\n");
    sb.append("    dateEpoch: ").append(toIndentedString(dateEpoch)).append("\n");
    sb.append("    day: ").append(toIndentedString(day)).append("\n");
    sb.append("    astro: ").append(toIndentedString(astro)).append("\n");
    sb.append("    hour: ").append(toIndentedString(hour)).append("\n");
    sb.append("}");
    return sb.toString();
  }

  /**
   * Convert the given object to string with each line indented by 4 spaces
   * (except the first line).
   */
  private String toIndentedString(java.lang.Object o) {
    if (o == null) {
      return "null";
    }
    return o.toString().replace("\n", "\n    ");
  }
}