Skip to content

Version 2.1.0 - Fix Floating Point Precision Errors

Compare
Choose a tag to compare
@JonMcPherson JonMcPherson released this 06 Jul 20:02
· 5 commits to master since this release
a2bcf65

NuGet Package Release: https://www.nuget.org/packages/OpenLocationCode/2.1.0

Release Notes

  • Implemented a new algorithm for Encode() and Decode() that uses 64-bit integer arithmetic to avoid floating point precision errors.
  • The CodeArea class was improved without any breaking changes
    • Added the CodeLength property as the length of the decoded Open Location Code.
    • Add new publicly accessible GeoArea class which now contains the generic area properties and methods and is extended by CodeArea.
    • The CodeArea constructor is still not publicly accessible to ensure that all CodeArea instances represent a valid OLC area.
  • The unit tests were improved to read and parse the test_data CSV files from the original open-location-code project.
    • The encoding.csv and decoding.csv TestData files also include new test cases for these changes.
    • No unit tests or test cases were removed (only added).