Jakar.Extensions 9.18.8

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

Jakar.Extensions

Contributions and Ideas are Welcome.

Overview

Jakar.Extensions is a .NET library that includes a variety of extensions and helper methods designed to streamline and enhance the development process. This package provides utility functions for common tasks, making your code cleaner and more maintainable.

Installation

You can install the Jakar.Extensions package via Nuget:

dotnet add package Jakar.Extensions

Alternatively, you can use the NuGet Package Manager in Visual Studio.

Features and Hhighlights of the extensions provided by this package.

Base classes

  • BaseClass : A base class that implements the INotifyPropertyChanged and INotifyPropertyChanging interface.
  • ObservableRecord : A base record that implements the INotifyPropertyChanged and INotifyPropertyChanging interface.

Collection

  • ObservableConcurrentDictionary : A thread-safe dictionary that supports change notifications.
  • ObservableDictionary : A dictionary that supports change notifications.
  • ConcurrentObservableCollection : A thread-safe collection that supports change notifications.
  • ConcurrentHashSet : A thread-safe hash set.
  • ConcurrentDeque : A thread-safe queue.
  • FixedSizedDeque : A fixed-size deque.
  • FixedSizedQueue : A fixed-size queue.

HTTP

  • WebRequester : A wrapper for System.Net.Http.HttpClient that simplifies the process of making HTTP requests and accepts an IHostInfo object to provide the base Uri. Also supports automatic retries.
  • WebHandler : An intermediate class that provides a way to handle the response from the WebRequester class.
  • WebResponse : The representation of the response from the WebRequester class.
  • Status : An enumration of the possible HTTP status codes.
  • MimeType : An enumeration of the possible MIME types.
  • MimeTypeNames : The equivalent string representation of the MimeType enumration.

Miscellaneous

  • SecuredString : A class that provides a way to store sensitive data in memory securely.
  • Validate : A static class that provides a way to validate various strings and states.
  • Tasks : A static class that provides a way to handle tasks such as SafeFireAndForget.
  • TypeExtensions : A static class that provides methods to see if they are ISet, IList or IDictionary and get the types or see if its a built in class or struct, or if its nullable.
  • IDataProtector and IDataProtectorProvider : A class to encrypt and decrypt strings.
  • ErrorOrResult : A struct that represents a result or an error.
  • LocalFile : A class that provides a way to easily handle local files such as reading and writing.
  • LocalDirectory : A class that provides a way to easily manage local directories such as creating and deleting, and getting files.
  • PasswordValidator : A class that provides an efficient way to validate passwords.
  • LoginRequest : A standard way to handle login requests.

AsyncLinq

Many of the following methods have overloads:

  • Average
  • AsAsyncEnumerable
  • IsEmpty
  • ToHashSet
  • ToList
  • GetArray
  • ToArray
  • Sorted
  • ToObservableCollection
  • Enumerate
  • EnumeratePairs
  • Append
  • Prepend
  • Cast
  • CastSafe
  • Distinct
  • DistinctBy
  • Skip
  • SkipLast
  • SkipWhile
  • Where
  • Select
  • Consolidate
  • ConsolidateUnique
  • WhereNotNull
  • WhereNotNullAsync
  • All
  • Any
  • ForEachAsync
  • ForEachParallelAsync
  • WhenAllParallelAsync
  • ForEach
  • ForEachParallel
  • Max
  • Min
  • Add
  • AddOrUpdate
  • Remove
  • TryAdd
  • AddDefault
  • Random
  • RandomValues
  • RandomKeys
  • Range
  • First
  • FirstOrDefault
  • Last
  • LastOrDefault
  • Single
  • SingleOrDefault

Hashes

Many of the following methods have overloads:

  • GetHash
  • Hash128
  • Hash
  • ToBytes
  • Hash_MD5
  • Hash_SHA1
  • Hash_SHA256
  • Hash_SHA384
  • Hash_SHA512
  • HashAsync
  • HashAsync_MD5
  • HashAsync_SHA1
  • HashAsync_SHA256
  • HashAsync_SHA384
  • HashAsync_SHA512

Types

Many of the following methods have overloads:

  • GetJsonIsRequired
  • GetJsonProperty
  • GetJsonKey
  • IsAnyBuiltInType
  • IsBuiltInNullableType
  • IsBuiltInType
  • IsGenericType
  • IsNullableType
  • IsInitOnly
  • IsEqualType
  • IsOneOfType
  • Construct
  • HasInterface
  • IsCollection
  • IsDictionary
  • IsDictionaryEntry
  • IsKeyValuePair
  • IsList
  • IsSet
  • MethodInfo
  • GetParameterInfo
  • MethodName
  • MethodSignature
  • MethodClass
  • IsNullable
  • TryGetUnderlyingEnumType

Spans

Many of the following methods have overloads:

  • Average
  • ContainsAny
  • ContainsAnyExcept
  • IndexOfAnyExcept
  • IndexOfAny
  • LastIndexOfAny
  • LastIndexOfAnyExcept
  • Contains
  • ContainsAll
  • ContainsNone
  • EndsWith
  • StartsWith
  • AsBytes
  • IsNullOrWhiteSpace
  • SequenceEqualAny
  • SequenceEqual
  • LastIndexOf
  • Enumerate
  • AsSpan
  • AsReadOnlySpan
  • CopyTo
  • TryCopyTo
  • CreateSpan
  • CreateValue
  • Create
  • QuickSort
  • First
  • FirstOrDefault
  • All
  • Any
  • Single
  • SingleOrDefault
  • Where
  • WhereValues
  • Select
  • SelectValues
  • Count
  • Join
  • Max
  • ToMemoryStream
  • AsMemory
  • AsReadOnlyMemory
  • AsArraySegment
  • TryAsSegment
  • ToMemory
  • ToReadOnlyMemory
  • ConvertToString
  • Min
  • As
  • Replace
  • RemoveAll
  • Slice
  • Sum
  • Trim
  • TrimEnd
  • TrimStart
  • ClampStart
  • ClampEnd

License

This project is licensed under the MIT License. See the LICENSE file for details. Contributing

Contributions are welcome! Please open an issue or submit a pull request on GitHub.

Product Compatible and additional computed target framework versions.
.NET net9.0 is compatible.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  net10.0 was computed.  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 (4)

Showing the top 4 NuGet packages that depend on Jakar.Extensions:

Package Downloads
Jakar.Database

Package Description

Jakar.Extensions.Blazor

Extensions to aid in development.

Jakar.Extensions.Serilog

Extensions to aid in development.

Jakar.Shapes

Extensions to aid in development.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
9.19.1 166 10/23/2025
9.19.0 92 10/17/2025
9.18.10 167 10/9/2025
9.18.9 169 10/9/2025
9.18.8 170 10/6/2025
9.18.7 169 10/6/2025
9.18.6 176 10/6/2025
9.18.5 170 10/3/2025
9.18.4 188 9/29/2025
9.18.3 179 9/26/2025
9.18.2 184 9/25/2025
9.18.1 273 9/24/2025
9.18.0 178 9/24/2025
9.17.2 302 9/18/2025
9.17.1 310 9/17/2025
9.17.0 304 9/17/2025
9.16.2 123 9/12/2025
9.16.1 126 9/12/2025
9.16.0 162 9/12/2025 9.16.0 is deprecated because it has critical bugs.
9.15.0 267 8/13/2025 9.15.0 is deprecated because it has critical bugs.
9.14.3 160 7/31/2025
9.14.2 136 7/30/2025
9.14.1 166 7/29/2025
9.14.0 135 7/29/2025
9.13.1 220 7/13/2025
9.13.0 188 7/13/2025
9.12.2 129 7/5/2025
9.12.1 130 7/4/2025
9.12.0 190 7/4/2025
9.11.0 196 6/25/2025
9.10.1 160 6/20/2025
9.10.0 222 6/19/2025
9.8.0 236 5/5/2025
9.7.3 291 4/16/2025
9.7.2 290 4/15/2025
9.7.1 294 4/15/2025
9.7.0 298 4/15/2025
9.6.0 550 3/26/2025
9.5.2 165 3/14/2025
9.5.1 185 3/14/2025
9.5.0 196 3/14/2025
9.4.0 298 3/6/2025
9.3.3 300 3/6/2025
9.3.2 315 3/5/2025
9.3.1 315 3/5/2025
9.3.0 314 3/5/2025
9.2.2 220 2/12/2025
9.2.1 201 2/12/2025
9.2.0 206 2/12/2025
9.1.1 191 1/24/2025
9.1.0 178 1/24/2025
9.0.5 231 1/10/2025
9.0.4 201 1/10/2025
9.0.3 201 12/19/2024
9.0.2 178 12/17/2024
9.0.1 211 12/15/2024
9.0.0 246 11/25/2024
8.13.3 231 9/28/2024
8.13.2 230 9/11/2024
8.13.1 289 9/10/2024
8.13.0 232 9/9/2024
8.12.4 285 8/22/2024
8.12.3 321 7/1/2024
8.12.2 266 6/19/2024
8.12.1 241 6/18/2024
8.12.0 265 6/17/2024
8.11.9 237 6/14/2024
8.11.8 219 6/14/2024
8.11.7 248 6/13/2024
8.11.6 235 6/13/2024
8.11.5 233 6/8/2024
8.11.4 229 6/8/2024
8.11.3 225 6/6/2024
8.11.2 225 5/31/2024
8.11.1 219 5/31/2024
8.11.0 218 5/31/2024
8.10.4 266 5/21/2024
8.10.3 259 5/14/2024
8.10.2 263 5/2/2024
8.10.1 217 5/2/2024
8.10.0 205 5/1/2024
8.9.1 213 5/1/2024
8.9.0 297 4/30/2024
8.8.2 251 4/29/2024
8.8.1 250 4/29/2024
8.8.0 231 4/29/2024
8.7.1 306 4/28/2024
8.7.0 243 4/28/2024
8.6.0 309 4/26/2024
8.5.0 265 4/26/2024
8.4.0 271 4/25/2024
8.3.3 247 4/24/2024
8.3.2 228 4/23/2024
8.3.1 232 4/9/2024
8.3.0 214 4/9/2024
8.2.11 242 4/8/2024
8.2.10 230 4/5/2024
8.2.9 277 4/4/2024
8.2.8 208 4/4/2024
8.2.7 225 4/4/2024
8.2.6 282 4/4/2024
8.2.5 249 4/4/2024
8.2.4 233 4/4/2024
8.2.3 234 4/4/2024
8.2.2 231 4/4/2024
8.2.0 252 4/4/2024
8.1.0 262 4/3/2024
8.0.3 262 4/3/2024
8.0.2 228 4/3/2024
8.0.1 258 4/3/2024
8.0.0 255 4/2/2024
7.7.1 274 4/1/2024
7.7.0 268 4/1/2024
7.6.6 319 2/27/2024
7.6.5 516 1/2/2024
7.6.4 416 1/2/2024
7.6.3 458 1/2/2024
7.6.2 477 12/22/2023
7.6.1 526 12/19/2023
7.6.0 521 12/13/2023
7.5.2 509 12/9/2023 7.5.2 is deprecated because it has critical bugs.
7.5.1 564 12/9/2023 7.5.1 is deprecated because it has critical bugs.
7.5.0 521 12/9/2023 7.5.0 is deprecated because it has critical bugs.
7.4.0 554 12/8/2023 7.4.0 is deprecated because it has critical bugs.
7.3.2 475 12/5/2023 7.3.2 is deprecated because it has critical bugs.
7.3.1 462 12/5/2023 7.3.1 is deprecated because it has critical bugs.
7.3.0 482 12/5/2023 7.3.0 is deprecated because it has critical bugs.
7.2.0 549 12/1/2023 7.2.0 is deprecated because it has critical bugs.
7.1.1 584 11/30/2023 7.1.1 is deprecated because it has critical bugs.
7.1.0 485 11/30/2023 7.1.0 is deprecated because it has critical bugs.
7.0.0 486 11/15/2023
6.9.2 542 11/5/2023
6.9.1 596 10/31/2023
6.9.0 530 10/31/2023
6.8.8 555 10/10/2023
6.8.7 607 10/3/2023
6.8.6 589 9/21/2023
6.8.5 555 9/21/2023
6.8.4 561 9/17/2023
6.8.3 718 8/29/2023
6.8.2 649 8/21/2023
6.8.1 883 7/14/2023
6.8.0 763 6/27/2023
6.7.30 796 6/27/2023
6.7.29 853 5/22/2023
6.7.28 819 5/8/2023
6.7.27 1,027 5/1/2023
6.7.26 923 5/1/2023 6.7.26 is deprecated because it has critical bugs.
6.7.25 957 5/1/2023 6.7.25 is deprecated because it has critical bugs.
6.7.24 905 4/30/2023
6.7.23 1,026 4/26/2023
6.7.22 779 4/25/2023
6.7.21 926 4/17/2023
6.7.20 888 3/31/2023
6.7.19 851 3/30/2023
6.7.18 1,043 3/30/2023
6.7.17 904 3/23/2023
6.7.16 831 3/22/2023
6.7.15 826 3/22/2023
6.7.14 888 3/22/2023
6.7.13 982 3/17/2023
6.7.12 925 3/17/2023
6.7.11 920 3/16/2023
6.7.10 934 3/16/2023
6.7.9 925 3/10/2023
6.7.8 1,057 3/6/2023
6.7.7 915 3/4/2023
6.7.6 919 3/4/2023
6.7.5 1,251 3/4/2023
6.7.4 942 3/3/2023
6.7.3 1,247 3/3/2023
6.7.2 1,249 3/1/2023
6.7.1 1,262 3/1/2023
6.6.4 1,132 2/15/2023
6.6.3 935 2/15/2023
6.6.2 1,133 2/15/2023
6.6.1 934 2/15/2023
6.6.0 971 2/12/2023
6.5.1 1,336 1/27/2023
6.4.4 1,246 1/21/2023
6.4.3 932 1/21/2023
6.4.2 1,083 12/1/2022
6.4.1 1,092 12/1/2022
6.4.0 1,266 11/21/2022
6.3.2 1,166 11/16/2022
6.3.1 1,091 11/14/2022
6.3.0 1,080 11/14/2022
6.2.2 1,370 11/11/2022
6.2.1 1,021 11/11/2022
6.2.0 1,121 11/11/2022
6.1.4 1,335 10/17/2022
6.1.3 1,250 10/11/2022
6.1.2 1,145 10/9/2022
6.1.1 1,048 10/6/2022
6.1.0 1,137 10/6/2022
6.0.5 1,213 10/4/2022
6.0.4 1,180 10/1/2022
6.0.3 1,171 9/30/2022
6.0.2 1,328 9/22/2022
6.0.1 1,119 9/22/2022
6.0.0.69-beta 826 9/20/2022
6.0.0.68-beta 867 9/19/2022
6.0.0.67-beta 802 9/19/2022
6.0.0.66-beta 871 9/19/2022
6.0.0.65-beta 865 9/17/2022
6.0.0.64-beta 820 9/16/2022
6.0.0.63-beta 802 9/15/2022
6.0.0.62-beta 915 9/14/2022
6.0.0.61-beta 886 9/14/2022
6.0.0.60-beta 903 9/13/2022
6.0.0.59-beta 953 9/13/2022
6.0.0.58-beta 1,094 9/13/2022
6.0.0.57-beta 817 9/11/2022
6.0.0.56-beta 794 9/11/2022
6.0.0.55-beta 875 9/8/2022
6.0.0.54-beta 827 9/6/2022
6.0.0.53-beta 815 9/5/2022
6.0.0.52-beta 763 9/1/2022
6.0.0.51-beta 846 8/31/2022
6.0.0.50-beta 780 8/30/2022
6.0.0.49-beta 838 8/30/2022
6.0.0.48-beta 858 8/30/2022
6.0.0.47-beta 838 8/29/2022
6.0.0.46-beta 802 8/21/2022
6.0.0.45-beta 813 8/16/2022
6.0.0.44-beta 823 8/15/2022
6.0.0.43-beta 814 8/13/2022
6.0.0.42-beta 825 8/10/2022
6.0.0.41-beta 818 8/5/2022
6.0.0.40-beta 799 8/4/2022
6.0.0.39-beta 791 8/4/2022
6.0.0.38-beta 781 8/3/2022
6.0.0.37-beta 837 8/3/2022
6.0.0.36-beta 733 7/21/2022
6.0.0.35-beta 834 7/12/2022
6.0.0.34-beta 801 7/1/2022
6.0.0.33-beta 807 7/1/2022
6.0.0.32-beta 797 7/1/2022
6.0.0.31-beta 853 7/1/2022
6.0.0.30-beta 893 6/30/2022
6.0.0.29-beta 805 6/24/2022
6.0.0.28-beta 815 6/24/2022
6.0.0.27-beta 776 6/23/2022
6.0.0.26-beta 828 6/22/2022
6.0.0.25-beta 880 6/16/2022
6.0.0.24-beta 823 6/10/2022
6.0.0.23-beta 863 6/9/2022
6.0.0.22-beta 841 6/9/2022
6.0.0.21-beta 818 6/8/2022
6.0.0.17-beta 827 6/1/2022
6.0.0.16-beta 773 5/24/2022
6.0.0.15-beta 755 5/23/2022
6.0.0.14-beta 838 5/19/2022
6.0.0.13-beta 763 5/13/2022
6.0.0.12-beta 762 5/10/2022
6.0.0.7-beta 771 5/10/2022
6.0.0.6-beta 722 4/28/2022
6.0.0.5-beta 803 4/22/2022
6.0.0.4-beta 817 4/21/2022
6.0.0.3-beta 819 4/21/2022
6.0.0.2-beta 823 4/20/2022
6.0.0.1-beta 835 4/20/2022
6.0.0 1,758 9/21/2022
5.9.3 1,377 4/15/2022 5.9.3 is deprecated because it has critical bugs.
5.9.2 1,220 4/15/2022
5.9.1 1,167 4/15/2022
5.9.0 1,209 4/15/2022
5.8.2 1,224 4/12/2022
5.8.1 1,161 4/11/2022
5.8.0 1,470 4/11/2022
5.7.1 1,235 4/8/2022
5.7.0 1,522 4/8/2022
5.6.0 1,232 3/29/2022
5.5.0 1,212 3/28/2022
5.4.0 1,517 3/28/2022
5.3.0 1,466 3/23/2022
5.2.7 1,196 3/21/2022
5.2.5 1,241 3/19/2022
5.2.4 1,166 3/19/2022
5.2.3 1,194 3/18/2022
5.2.2 1,152 3/18/2022
5.2.1 1,186 3/18/2022
5.2.0 1,174 3/17/2022
5.1.2 1,204 3/17/2022
5.1.1 1,231 3/17/2022
5.1.0 1,191 3/16/2022

Bug Fixes