Soenneker.Enums.DateRangeType 4.0.181

Prefix Reserved
dotnet add package Soenneker.Enums.DateRangeType --version 4.0.181
                    
NuGet\Install-Package Soenneker.Enums.DateRangeType -Version 4.0.181
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Soenneker.Enums.DateRangeType" Version="4.0.181" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Soenneker.Enums.DateRangeType" Version="4.0.181" />
                    
Directory.Packages.props
<PackageReference Include="Soenneker.Enums.DateRangeType" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Soenneker.Enums.DateRangeType --version 4.0.181
                    
#r "nuget: Soenneker.Enums.DateRangeType, 4.0.181"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Soenneker.Enums.DateRangeType@4.0.181
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Soenneker.Enums.DateRangeType&version=4.0.181
                    
Install as a Cake Addin
#tool nuget:?package=Soenneker.Enums.DateRangeType&version=4.0.181
                    
Install as a Cake Tool

alternate text is missing from this package README image alternate text is missing from this package README image alternate text is missing from this package README image alternate text is missing from this package README image

Soenneker.Enums.DateRangeType

A string-backed enum-value type for selecting a predefined calendar period or a caller-supplied custom date range.

Install

dotnet add package Soenneker.Enums.DateRangeType

Usage

using Soenneker.Enums.DateRangeType;

DateRangeType selection = DateRangeType.PreviousMonth;
string wireValue = selection.Value; // "PreviousMonth"

if (DateRangeType.TryFromValue(input, out DateRangeType? parsed))
{
    // Resolve parsed to boundaries using your application's calendar rules
}

Available values:

  • Today
  • Yesterday
  • CurrentWeek
  • PreviousWeek
  • CurrentMonth
  • PreviousMonth
  • CurrentYear
  • PreviousYear
  • Custom

System.Text.Json serializes the type as the shown string value. FromValue throws for unknown input; use TryFromValue for request values. FromName and TryFromName are also generated for member-name lookup.

This package identifies a range selection; it does not calculate start or end timestamps. The consuming application must define its time zone, first day of the week, inclusive/exclusive boundary policy, and the explicit boundaries required by Custom. Capture the reference time once before resolving relative selections so a request cannot cross a calendar boundary midway through calculation.

Product Compatible and additional computed target framework versions.
.NET net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (1)

Showing the top 1 NuGet packages that depend on Soenneker.Enums.DateRangeType:

Package Downloads
Soenneker.Extensions.DateRangeType

A collection of helpful DateRangeType enum extension methods

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
4.0.181 41 10/15/2026
4.0.180 46 10/14/2026
4.0.178 52 10/14/2026
4.0.177 51 10/14/2026
4.0.176 42 10/14/2026
4.0.175 42 10/14/2026
4.0.171 58 10/13/2026
4.0.170 48 10/13/2026
4.0.169 82 10/12/2026
4.0.167 73 10/12/2026
4.0.166 97 10/11/2026
4.0.165 60 10/11/2026
4.0.164 122 10/11/2026
4.0.163 353 9/30/2026
4.0.162 140 9/25/2026
4.0.161 98 9/24/2026
4.0.160 91 9/24/2026
4.0.159 436 9/15/2026
4.0.158 105 9/15/2026
4.0.156 270 9/12/2026
Loading failed

Updated Multiple NuGet packages