Function open_notify::blocking::spot [−][src]
pub fn spot(
latitude: f64,
longitude: f64,
altitude: f64
) -> Result<Vec<Spot>, String>
Expand description
Fetches a ISS spotting update once and stops the thread immediately after success then returns the update.
Parameters
latitude
: latitude in decimal degrees of the ground station. required Range: -90..90longitude
: longitude in decimal degress of the ground station. required Range: -180..180altitude
: altitude in meters of the ground station. optional. Range: 0..10000poll_mins
: Update interval:> 0
: duration of poll period in minutes (10
is recommended)= 0
: thread will terminate after the first successful update.
Return value
- ⇒
Ok(Vec<Spot>)
: vector of upcoming spotting events - ⇒
Err(String)
: Error message about any occured http or json issue - e.g. `500 Internal Server Error“ - some json parser error message if response from open-notify.org could not be parsed