Soenneker.Enums.SortDirections 4.0.71

Prefix Reserved
There is a newer version of this package available.
See the version list below for details.
dotnet add package Soenneker.Enums.SortDirections --version 4.0.71
                    
NuGet\Install-Package Soenneker.Enums.SortDirections -Version 4.0.71
                    
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.SortDirections" Version="4.0.71" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Soenneker.Enums.SortDirections" Version="4.0.71" />
                    
Directory.Packages.props
<PackageReference Include="Soenneker.Enums.SortDirections" />
                    
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.SortDirections --version 4.0.71
                    
#r "nuget: Soenneker.Enums.SortDirections, 4.0.71"
                    
#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.SortDirections@4.0.71
                    
#: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.SortDirections&version=4.0.71
                    
Install as a Cake Addin
#tool nuget:?package=Soenneker.Enums.SortDirections&version=4.0.71
                    
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.SortDirections

A string-backed enum-value type for carrying an ascending or descending sort direction in query contracts.

Install

dotnet add package Soenneker.Enums.SortDirections

Usage

using Soenneker.Enums.SortDirections;

SortDirection direction = SortDirection.Asc;
string wireValue = direction.Value; // "asc"

if (SortDirection.TryFromValue(input, out SortDirection? parsed))
{
    direction = parsed;
}

Available wire values:

  • SortDirection.Asc"asc"
  • SortDirection.Desc"desc"

System.Text.Json serializes the type as its lowercase value and restores recognized values to the shared static instances. FromValue throws for unknown input; use TryFromValue for query parameters. FromName and TryFromName use the C# member names, "Asc" and "Desc".

The type supplies direction only. The query implementation defines ordering for strings, nulls, dates, and locale-sensitive data. Validate sort fields against an explicit allowlist and build queries with the target API or database's parameterized expression mechanisms; a valid direction does not make an arbitrary field name safe.

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.SortDirections:

Package Downloads
Soenneker.Dtos.Options.OrderBy

An object for ordering during querying

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
4.0.72 425 9/4/2026
4.0.71 1,173 8/30/2026
4.0.70 343 8/30/2026
4.0.69 88 8/30/2026
4.0.68 86 8/30/2026
4.0.67 87 8/29/2026
4.0.66 2,284 8/21/2026
4.0.65 723 8/18/2026
4.0.64 279 8/18/2026
4.0.63 105 8/18/2026
4.0.62 1,875 8/7/2026
4.0.61 1,008 7/28/2026
4.0.60 231 7/28/2026
4.0.59 113 7/27/2026
4.0.58 2,593 7/16/2026
4.0.57 104 7/16/2026
4.0.56 124 7/16/2026
4.0.55 2,442 7/3/2026
4.0.54 1,460 6/19/2026
4.0.53 338 6/18/2026
Loading failed

Update dependency Soenneker.Gen.EnumValues to 4.0.46 (#101)