lonlat

Crates.iolonlat
lib.rslonlat
version1.1.0
sourcesrc
created_at2020-09-14 14:35:25.346393
updated_at2020-09-19 00:02:44.190901
descriptionLonLat and LonLatAlt geo-location types and utils.
homepage
repositoryhttps://github.com/usagi/lonlat
max_upload_size
id288629
size50,204
Usagi Ito (usagi)

documentation

README

lonlat

LonLat and LonLatAlt geo-location types and utils.

Features

  • LonLat and LonLatAlt types; lon: Angle, lat: Angle (, alt: Length )
    • .try_from -> LonLat -> .to_string_XXX
      • A human readable degrees-minutes-seconds notation patterns. eg, "42°49′36”N 140°48′41”E"
      • The GeoURI pattern. eg, geo:42.826667,140.811389
      • Additional language "ja-JP"(Japanese; 日本語) supports. eg, "北緯42度49分36秒 東経140度48分41秒"
  • lonlat::dimensions::Angle = measurement::Angle + extension traits
    • .as_string_radians -> "2.4670994982555996 [rad]"
    • .as_string_degrees -> "141.35438888888888°"
    • .as_string_minutes -> "8481.263333333332’"
    • .as_string_seconds -> "508875.79999999993”"
    • .as_string_dms_180 -> "+141°21’15.8”"; "ja-JP" feature -> "141度21分15.8秒"
    • .as_string_dms_ns -> "+141°21’15.8”N"; "ja-JP" feature -> "北緯141度21分15.8秒"
    • .as_string_dms_90 -> "+41°21’15.8”"; "ja-JP" feature -> "41度21分15.8秒"
    • .as_string_dms_ew -> "+41°21’15.8”E"; "ja-JP" feature -> "東経41度21分15.8秒"
    • And more patterns.

Note: To enable "ja-JP" features if you need additional Japanese features.

Example and Tests

License

Author

Commit count: 4

cargo fmt