feat(weather): temperature object
This commit is contained in:
parent
9bf42e49bc
commit
363db6346b
@ -1,5 +1,27 @@
|
|||||||
package eirb.pg203;
|
package eirb.pg203;
|
||||||
|
|
||||||
public class Temperature {
|
import java.time.Instant;
|
||||||
|
|
||||||
|
public class Temperature {
|
||||||
|
private String city;
|
||||||
|
private Instant date;
|
||||||
|
private float temp;
|
||||||
|
|
||||||
|
Temperature(float temp, String city, Instant date) {
|
||||||
|
this.temp = temp;
|
||||||
|
this.city = city;
|
||||||
|
this.date = date;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getCity() {
|
||||||
|
return city;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Instant getDate() {
|
||||||
|
return date;
|
||||||
|
}
|
||||||
|
|
||||||
|
public float getTemp() {
|
||||||
|
return temp;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user