Skip to content

v1.2.0

Choose a tag to compare

@abjerner abjerner released this 12 Nov 17:18

Installation

Install via NuGet - either via the .NET CLI:

dotnet add package Skybrud.Essentials --version 1.2.0

or the NuGet Package Manager:

Install-Package Skybrud.Essentials -Version 1.2.0

Changelog

This release introduces new functionality, improves existing utilities, and incorporates features and improvements from the v1.1.x package.

Added

  • Added TimeSpanSecondsConverter and TimeSpanMillisecondsConverter for Newtonsoft.Json (3d99e44)

    • Ported from the v1.1 branch.
  • Added explicit UNIX time formats (5d9b9ef)

    • Introduced TimeUtils.UnixTimeSeconds and TimeUtils.UnixTimeMilliseconds to distinguish between UNIX timestamps expressed in seconds and milliseconds.
    • Marked the existing TimeUtils.UnixTime as obsolete in favor of TimeUtils.UnixTimeSeconds.
  • Added support for DateOnly and TimeOnly (8bb039f)

    • Extended EssentialsDate and EssentialsTime with additional constructors and methods supporting DateOnly and TimeOnly.

Improved

  • Improved geographic distance calculations (fa6a253)

    • Updated GetDistance methods to use Vincenty's formula, with Haversine as a fallback.
    • Added GetSphericalLawOfCosinesDistance methods to preserve the previous GetDistance implementation.
    • Added GetHaversineDistance methods.
    • Added GetVincentyDistance and TryGetVincentyDistance methods.
  • Improved boolean string parsing consistency (fa9164f)

    • Updated all StringUtils.TryParseBoolean overloads to consistently recognize yes, y, no, and n.

Other Changes

  • Ported miscellaneous functionality and improvements from v1.1.x (6cd3789)
    • Incorporated additional logic and improvements from the v1.1 branch.