Extensions to aid in development.
$ dotnet add package Jakar.ExtensionsContributions and Ideas are Welcome.
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.
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.
BaseClass : A base class that implements the INotifyPropertyChanged and INotifyPropertyChanging interface.ObservableRecord : A base record that implements the INotifyPropertyChanged and INotifyPropertyChanging interface.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.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.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.Many of the following methods have overloads:
AverageAsAsyncEnumerableIsEmptyToHashSetToListGetArrayToArraySortedToObservableCollectionEnumerateEnumeratePairsAppendPrependCastCastSafeDistinctDistinctBySkipSkipLastSkipWhileWhereSelectConsolidateConsolidateUniqueWhereNotNullWhereNotNullAsyncAllAnyForEachAsyncForEachParallelAsyncWhenAllParallelAsyncForEachForEachParallelMaxMinAddAddOrUpdateRemoveTryAddAddDefaultRandomRandomValuesRandomKeysRangeFirstFirstOrDefaultLastLastOrDefaultSingleSingleOrDefaultMany of the following methods have overloads:
GetHashHash128HashToBytesHash_MD5Hash_SHA1Hash_SHA256Hash_SHA384Hash_SHA512HashAsyncHashAsync_MD5HashAsync_SHA1HashAsync_SHA256HashAsync_SHA384HashAsync_SHA512Many of the following methods have overloads:
GetJsonIsRequiredGetJsonPropertyGetJsonKeyIsAnyBuiltInTypeIsBuiltInNullableTypeIsBuiltInTypeIsGenericTypeIsNullableTypeIsInitOnlyIsEqualTypeIsOneOfTypeConstructHasInterfaceIsCollectionIsDictionaryIsDictionaryEntryIsKeyValuePairIsListIsSetMethodInfoGetParameterInfoMethodNameMethodSignatureMethodClassIsNullableTryGetUnderlyingEnumTypeMany of the following methods have overloads:
AverageContainsAnyContainsAnyExceptIndexOfAnyExceptIndexOfAnyLastIndexOfAnyLastIndexOfAnyExceptContainsContainsAllContainsNoneEndsWithStartsWithAsBytesIsNullOrWhiteSpaceSequenceEqualAnySequenceEqualLastIndexOfEnumerateAsSpanAsReadOnlySpanCopyToTryCopyToCreateSpanCreateValueCreateQuickSortFirstFirstOrDefaultAllAnySingleSingleOrDefaultWhereWhereValuesSelectSelectValuesCountJoinMaxToMemoryStreamAsMemoryAsReadOnlyMemoryAsArraySegmentTryAsSegmentToMemoryToReadOnlyMemoryConvertToStringMinAsReplaceRemoveAllSliceSumTrimTrimEndTrimStartClampStartClampEndThis 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.