Package com.aerisweather.aeris.response
Class MoonphasesResponse
- java.lang.Object
-
- com.aerisweather.aeris.response.AerisFriendlyResponse
-
- com.aerisweather.aeris.response.MoonphasesResponse
-
public class MoonphasesResponse extends AerisFriendlyResponse
Object to make thesunmoon/moonphases
endpoint response more friendly to determine what parts of the AerisDataJSON have come back in the response.
-
-
Field Summary
-
Fields inherited from class com.aerisweather.aeris.response.AerisFriendlyResponse
response
-
-
Constructor Summary
Constructors Constructor Description MoonphasesResponse(AerisDataJSON data)
Constructor the the sunmoon/moonphases Response.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Number
getCode()
Get the code for the moon phaseString
getDateTimeISO()
Gets the date time ISO for the moon phase.String
getName()
Get the name of the moon phaseNumber
getTimestamp()
Gets the timestamp for the moon phase.-
Methods inherited from class com.aerisweather.aeris.response.AerisFriendlyResponse
getDataSource, getId, getLocation, getPlace, getProfile, getProfileTimezone, getRelative
-
-
-
-
Constructor Detail
-
MoonphasesResponse
public MoonphasesResponse(AerisDataJSON data)
Constructor the the sunmoon/moonphases Response. Wraps the JSON data into a friendlier object to determine what data is available.- Parameters:
data
- JSON data
-
-
Method Detail
-
getCode
public Number getCode()
Get the code for the moon phase- Returns:
- Number - code for moon phase
-
getName
public String getName()
Get the name of the moon phase- Returns:
- String - name of the moon phase
-
getDateTimeISO
public String getDateTimeISO()
Gets the date time ISO for the moon phase.- Returns:
- the date time
-
getTimestamp
public Number getTimestamp()
Gets the timestamp for the moon phase.- Returns:
- the timestamp
-
-