Extend.NET.Enum 2024.9.9.1335

There is a newer version of this package available.
See the version list below for details.
dotnet add package Extend.NET.Enum --version 2024.9.9.1335                
NuGet\Install-Package Extend.NET.Enum -Version 2024.9.9.1335                
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="Extend.NET.Enum" Version="2024.9.9.1335" />                
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add Extend.NET.Enum --version 2024.9.9.1335                
#r "nuget: Extend.NET.Enum, 2024.9.9.1335"                
#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.
// Install Extend.NET.Enum as a Cake Addin
#addin nuget:?package=Extend.NET.Enum&version=2024.9.9.1335

// Install Extend.NET.Enum as a Cake Tool
#tool nuget:?package=Extend.NET.Enum&version=2024.9.9.1335                

Extend.NET.Enum

Last Updated: 2024-09-09 13:35:43

📖 Overview

Extend.NET.Enum is part of the Extend.NET suite, providing a collection of powerful and easy-to-use extension methods for Enum types in .NET applications. These extensions aim to simplify common tasks and enhance developer productivity.

🧰 Extension Methods

GetAttributeOfType

Gets the first attribute of the specified type from the enum value.

GetBitFlags

Gets all individual bit flags set in the enum value.

GetDescription

Gets the description of an enum value.

GetDisplayName

Gets the display name of an enum value.

GetEnumDescription

Gets the description of an enum value.

T

Creates a dictionary of enum values with their names as keys.

GetEnumIndex

Gets the index of the enum value in the enum definition order.

GetEnumNameByValue

Gets the name of the enum value by its underlying integer value.

GetEnumValueByDescription

Gets the enum value that has the specified description attribute.

GetEnumValueByIndex

Gets the enum value at the specified index.

GetEnumValueByName

Gets the enum value by its name.

GetEnumValueCount

Gets the count of distinct values in the enum.

GetEnumValueFromInt

Converts an integer to its corresponding enum value.

GetEnumValueFromString

Converts a string to its corresponding enum value.

Min

Gets the range of integer values used in the enum.

GetEnumValues

Gets all values of the enum as a list.

string

Gets all enum values as key-value pairs, where the key is the enum value and the value is its string representation.

GetEnumValuesAsStringArray

Gets all enum values as an array of strings.

GetEnumValuesBetween

Gets all enum values between two specified values (inclusive).

GetEnumValuesExcept

Gets all enum values except the specified ones.

GetEnumValuesSorted

Gets all enum values sorted by their underlying integer value.

GetEnumValuesWithAttribute

Gets all enum values that have the specified attribute.

GetEnumValuesWithoutAttribute

Gets all enum values that do not have the specified attribute.

GetFlags

Gets all flags set in the enum value.

GetName

Gets the name of the enum value.

GetNames

Gets an array of the names of all the constants in the specified enumeration.

GetNextDistinctValue

Gets the next distinct value in the enum, skipping duplicate integer values.

GetNextValue

Gets the next value in the enum, or the first value if the current value is the last one.

GetPreviousValue

Gets the previous value in the enum, or the last value if the current value is the first one.

GetRandomValue

Gets a random value from the enum.

GetUnderlyingType

Gets the underlying type of the enum.

GetValues

Gets an array of all values of the specified enum type.

HasAnyFlag

Determines whether the enum value has any of the specified flags.

HasFlag

Determines whether the enum value has the specified flag.

IsDefined

Determines whether the specified value exists in the enum.

IsDefinedName

Determines whether the specified name exists in the enum.

IsEnumFlagSet

Checks if a specific flag is set in the enum value.

IsEnumValueInRange

Checks if the given integer value is within the range of defined enum values.

IsInRange

Checks if the enum value is within the specified range.

IsValidEnumValue

Checks if the given value is a valid enum value for the specified enum type.

Parse

Parses a string to the specified enum type.

ParseIgnoreCase

Parses a string to the enum value, ignoring case.

ToFriendlyString

Converts the enum value to a friendly string by inserting spaces before capital letters.

ToInt

Converts the enum value to its underlying integer value.

ToList

Converts an enum type to a list of its values.

ToLong

Converts the enum value to its underlying long value.

ToStringFast

Converts the enum value to its string representation using a cached approach for better performance.

ToStringWithSeparator

Converts the enum value to a string with a custom separator between words.

TryParse

Tries to parse a string to the specified enum type.

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

    • No dependencies.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
2024.9.9.1414 124 9/9/2024
2024.9.9.1402 130 9/9/2024
2024.9.9.1338 116 9/9/2024
2024.9.9.1335 114 9/9/2024
2024.9.9.1320 117 9/9/2024
2024.9.9.1225 121 9/9/2024
2024.9.9.1052 116 9/9/2024
2024.9.9.1044 121 9/9/2024