{"id":22045205,"url":"https://github.com/nigelhorne/geo-location-point","last_synced_at":"2025-05-08T07:45:18.536Z","repository":{"id":56840604,"uuid":"176567939","full_name":"nigelhorne/Geo-Location-Point","owner":"nigelhorne","description":"Location Information - stores a place/location by latitude and longitude","archived":false,"fork":false,"pushed_at":"2025-01-21T22:04:30.000Z","size":98,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-05-08T07:45:15.675Z","etag":null,"topics":["cpan","location","perl"],"latest_commit_sha":null,"homepage":"https://metacpan.org/pod/Geo::Location::Point","language":"Perl","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/nigelhorne.png","metadata":{"files":{"readme":"README.md","changelog":"Changes","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-03-19T17:46:15.000Z","updated_at":"2025-01-21T22:04:34.000Z","dependencies_parsed_at":"2025-01-21T16:27:23.823Z","dependency_job_id":"2be85316-b063-4835-adbf-beb4b71fbaa5","html_url":"https://github.com/nigelhorne/Geo-Location-Point","commit_stats":{"total_commits":88,"total_committers":4,"mean_commits":22.0,"dds":"0.17045454545454541","last_synced_commit":"8777f2de63f8b2dbcce9faaed2854a943d8e72d9"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nigelhorne%2FGeo-Location-Point","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nigelhorne%2FGeo-Location-Point/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nigelhorne%2FGeo-Location-Point/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nigelhorne%2FGeo-Location-Point/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nigelhorne","download_url":"https://codeload.github.com/nigelhorne/Geo-Location-Point/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253025333,"owners_count":21842409,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cpan","location","perl"],"created_at":"2024-11-30T13:12:14.749Z","updated_at":"2025-05-08T07:45:18.530Z","avatar_url":"https://github.com/nigelhorne.png","language":"Perl","funding_links":[],"categories":[],"sub_categories":[],"readme":"# NAME\n\nGeo::Location::Point - Location information\n\n# VERSION\n\nVersion 0.13\n\n# SYNOPSIS\n\nGeo::Location::Point encapsulates geographical point data with latitude and longitude.\nIt supports distance calculations,\ncomparison between points,\nand provides various convenience methods for attributes like latitude, longitude, and related string representations\n\n    use Geo::Location::Point;\n\n    my $location = Geo::Location::Point-\u003enew(latitude =\u003e 0.01, longitude =\u003e -71);\n\n# SUBROUTINES/METHODS\n\n## new\n\nInitialise a new object, accepting latitude and longitude via a hash or hash reference.\nTakes one optional argument 'key' which is an API key for [https://timezonedb.com](https://timezonedb.com) for looking up timezone data.\n\n    $location = Geo::Location::Point-\u003enew({ latitude =\u003e 0.01, longitude =\u003e -71 });\n\n## lat\n\n    print 'Latitude: ', $location-\u003elat(), \"\\n\";\n    print 'Longitude: ', $location-\u003elong(), \"\\n\";\n\n## latitude\n\nSynonym for lat().\n\n## long\n\n    print 'Latitude: ', $location-\u003elat(), \"\\n\";\n    print 'Longitude: ', $location-\u003elong(), \"\\n\";\n\n## lng\n\nSynonym for long().\n\n## longitude\n\nSynonym for long().\n\n## distance\n\nDetermine the distance between two geographical points,\nreturns a [Class::Measure::Length](https://metacpan.org/pod/Class%3A%3AMeasure%3A%3ALength) object.\n\n## equal\n\nCheck if two points are identical within a small tolerance.\n\n    my $loc1 = Geo::Location::Point-\u003enew(lat =\u003e 2, long =\u003e 2);\n    my $loc2 = Geo::Location::Point-\u003enew(lat =\u003e 2, long =\u003e 2);\n    print ($loc1 == $loc2), \"\\n\";       # Prints 1\n\n## not\\_equal\n\nAre two points different?\n\n    my $loc1 = Geo::Location::Point-\u003enew(lat =\u003e 2, long =\u003e 2);\n    my $loc2 = Geo::Location::Point-\u003enew(lat =\u003e 2, long =\u003e 2);\n    print ($loc1 != $loc2), \"\\n\";       # Prints 0\n\n## tz\n\nReturns the timezone of the location.\nNeeds [TimeZone::TimeZoneDB](https://metacpan.org/pod/TimeZone%3A%3ATimeZoneDB).\n\n## timezone\n\nSynonym for tz().\n\n## as\\_string\n\nGenerate a human-readable string describing the point,\nincorporating additional attributes like city or country if available.\n\n## as\\_uri\n\nConvert the point to a Geo URI scheme string (geo:latitude,longitude).\nSee [https://en.wikipedia.org/wiki/Geo\\_URI\\_scheme](https://en.wikipedia.org/wiki/Geo_URI_scheme).\nArguably it should return a [URI](https://metacpan.org/pod/URI) object instead.\n\n## attr\n\nGet or set arbitrary attributes, such as city or country.\n\n    $location-\u003ecity('London');\n    $location-\u003ecountry('UK');\n    print $location-\u003eas_string(), \"\\n\";\n    print \"$location\\n\";        # Calls as_string\n\n# AUTHOR\n\nNigel Horne \u003cnjh@bandsman.co.uk\u003e\n\nThis library is free software; you can redistribute it and/or modify\nit under the same terms as Perl itself.\n\n# BUGS\n\nThere is no validation on the attribute in the AUTOLOAD method,\nso typos such as \"citty\" will not be caught.\n\n# SEE ALSO\n\n[GIS::Distance](https://metacpan.org/pod/GIS%3A%3ADistance),\n[Geo::Point](https://metacpan.org/pod/Geo%3A%3APoint),\n[TimeZone::TimeZoneDB](https://metacpan.org/pod/TimeZone%3A%3ATimeZoneDB).\n\n# LICENSE AND COPYRIGHT\n\nCopyright 2019-2025 Nigel Horne.\n\nThe program code is released under the following licence: GPL2 for personal use on a single computer.\nAll other users (including Commercial, Charity, Educational, Government)\nmust apply in writing for a licence for use from Nigel Horne at \\`\u0026lt;njh at nigelhorne.com\u003e\\`.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnigelhorne%2Fgeo-location-point","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnigelhorne%2Fgeo-location-point","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnigelhorne%2Fgeo-location-point/lists"}