public class Condition extends Object implements Serializable, Cloneable
| Constructor and Description |
|---|
Condition() |
Condition(String text,
ConditionCode code,
int temperature,
Date date) |
| Modifier and Type | Method and Description |
|---|---|
Object |
clone() |
boolean |
equals(Object o) |
ConditionCode |
getCode()
Condition code
|
Date |
getDate()
Date recorded
|
int |
getTemperature()
Current Temperature
|
String |
getText()
Description of condition
|
int |
hashCode() |
void |
setCode(ConditionCode code)
Condition code
|
void |
setDate(Date date)
Date recorded
|
void |
setTemperature(int temperature)
Current Temperature
|
void |
setText(String text)
Description of condition
|
String |
toString() |
public Condition()
public Condition(String text, ConditionCode code, int temperature, Date date)
text - a textual description of conditions, for example, "Partly Cloudy"code - the condition code for this forecast.temperature - the current temperaturedate - the current date and timepublic String getText()
public void setText(String text)
text - a textual description of conditions, for example, "Partly Cloudy"public ConditionCode getCode()
public void setCode(ConditionCode code)
code - Condition codepublic int getTemperature()
Unitspublic void setTemperature(int temperature)
temperature - the current temperatureUnitspublic Date getDate()
public void setDate(Date date)
date - the current date and timeCopyright © 2021. All rights reserved.