Skip to content

Releases: srishanbhattarai/geoutils

0.5.1

07 Aug 18:57
Compare
Choose a tag to compare

0.5.0

02 Jul 03:34
Compare
Choose a tag to compare

0.5.0 adds optional Serde derive impls, and misc. Clippy fixes.

0.4.1 Minor update

05 Apr 05:57
Compare
Choose a tag to compare
  • Add normal derives to the Distance struct (#12)

0.4.0 release

19 Mar 02:30
Compare
Choose a tag to compare

Changes

  • Changed Haversine distance API to also return Distance introduced in 0.3.0
  • Make examples Rust 2018 compliant
  • Updated the README to fix discrepancies relating to the Distance API (#10)

0.3.0 release

19 Mar 02:26
Compare
Choose a tag to compare

This release introduces the Distance return type for the distance APIs instead of an f64 value which did not indicate the unit (it was meters).

Crucially, the API changed to the following:

extern crate geoutils;

use geoutils::Location;

let berlin = Location::new(52.518611, 13.408056);
let moscow = Location::new(55.751667, 37.617778);
let distance = berlin.distance_to(&moscow).unwrap();

println!("Distance = {}", distance.meters()); <-- ".meters()" instead of simply using "distance"

v0.2.0

02 Dec 08:43
Compare
Choose a tag to compare

Breaking Changes

  • The tuple fields for latitude and longitude from the location struct are no longer public. Instead, getters have been added named latitude() and longitude()
let loc = Location::new(123.012, 45.68);

// Previously
let lat = loc.0;
let lon = loc.1;

// Now
let lat = loc.latitude()
let lon = loc.longitude()

Changes

v0.1.0

02 Dec 08:38
Compare
Choose a tag to compare

Features

  • distance_to using Vincenty's inverse formula
  • is_in_circle for radial bounds check
  • center to get geo-center of a vector of coordinates