Class Astronomy
java.lang.Object
com.timeanddate.services.dataTypes.astro.Astronomy
- Author:
- Cato Auestad <cato@timeanddate.com>
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic Astronomy
Lists all sunrise/sunset events during the day.getName()
Object name.This element is only present if there are no astronomical events.This returns the hour and minute of the sunrise in DateTime format.This returns the hour and minute of the sunrise in DateTime format.
-
Constructor Details
-
Astronomy
public Astronomy()
-
-
Method Details
-
getName
Object name. Currently, the sun is the only supported astronomical object. -
getEvents
Lists all sunrise/sunset events during the day. -
getSpecial
This element is only present if there are no astronomical events. In this case it will indicate if the sun is up or down the whole day. -
getSunset
This returns the hour and minute of the sunrise in DateTime format. If there is no sunrise, null will be returned, but the Special-property will say whether or not the sun is up or down.- Returns:
- Returns sunset or null if there is no sunset that day.
- Throws:
NullPointerException
-
getSunrise
This returns the hour and minute of the sunrise in DateTime format. If there is no sunrise, null will be returned, but the Special-property will say whether or not the sun is up or down.- Returns:
- Returns sunrise or null if there is no sunrise that day.
-
fromNode
-