dotnet add package Epiforge.Extensions.Components --version 1.5.0
NuGet\Install-Package Epiforge.Extensions.Components -Version 1.5.0
<PackageReference Include="Epiforge.Extensions.Components" Version="1.5.0" />
paket add Epiforge.Extensions.Components --version 1.5.0
#r "nuget: Epiforge.Extensions.Components, 1.5.0"
// Install Epiforge.Extensions.Components as a Cake Addin #addin nuget:?package=Epiforge.Extensions.Components&version=1.5.0 // Install Epiforge.Extensions.Components as a Cake Tool #tool nuget:?package=Epiforge.Extensions.Components&version=1.5.0
Property Change Notification
This library offers the
PropertyChangeNotifier class, which you may inherit from to quickly get all the property utilities we're all tired of copying and pasting everywhere.
Just call the protected
OnPropertyChanging methods at the appropriate times from setters and compiler services will figure out what property you're in.
Or, if all you need to do is set the value of a field,
SetBackedProperty couldn't make it any easier or convenient to handle that as efficiently as possible.
DynamicPropertyChangeNotifier is also available if your class needs to be dynamic.
Be sure to set the protected
Logger property if you want the abstract class to log what's going on with property change notification.
This library features base classes that handle things we've written a thousand times over, this time involving disposal.
If you want to go with an implementation of the tried and true
IDisposable, just inherit from
Want a taste of the new
IAsyncDisposable? Then, inherit from
Or, if you want to support both, there's
Additionally, if your object needs to be dynamic, you can use
Each of these features abstract methods to actually do your disposal.
But all of the base classes feature:
- proper implementation of the finalizer and use of
- monitored access to disposal to ensure it can't happen twice
- the ability to override or "cancel" disposal by returning false from the abstract methods (e.g. you're reference counting and only want to dispose when your counter reaches zero)
- a protected
ThrowIfDisposedmethod you can call to before doing anything that requires you haven't been disposed
IsDisposedproperty the value (and change notifications) of which are handled for you
This library provides the
IDisposalStatus interface, which defines the
IsDisposed property and all the base classes implement it.
This library also provides the
INotifyDisposalOverridden interfaces, which add events that notify of these occurrences.
Be sure to set the protected
Logger property if you want the abstract class to log what's going on with disposal.
This library has useful tools for when you can't be certain of some things at compile time, such as types, methods, etc. While .NET reflection is immensely powerful, prior to .NET 7, it's not very quick. To address this, this library offers the following extension methods which will emit IL, generate delegates, and cache them for expedited use of Reflection:
ConstructorInfo.FastInvoke: call a constructor only known at runtime quickly
MethodInfo.FastInvoke: call a method only known at runtime quickly
PropertyInfo.FastGetValue: get the value of a property only known at runtime quickly
PropertyInfo.FastSetValue: set the value of a property only known at runtime quickly
Type.FastDefault: get the default value of a type only known at runtime quickly
Type.GetImplementationEvents: searches for the events of a type, including interfaces and interface inheritance
Type.GetImplementationMethods: searches for the methods of a type, including interfaces and interface inheritance
Type.GetImplementationProperties: searches for the properties of a type, including interfaces and interface inheritance
Use of these methods in .NET 7 or later will simply call the built-in methods, as they are now optimized.
This library also offers
FastEqualityComparer, which implement
IEqualityComaprer, respectively, but quickly use the methods of
EqualityComaprer<>.Default, respectively, to do their work.
In addition (pun intended), this library offers
GenericDivision, which will produce delegates that will perform the respective operations with values of supplied generic type arguments.
This library provides extension methods for dealing with exceptions:
GetFullDetails- creates a representation of an exception and all of its inner exceptions, including exception types, messages, and stack traces, and traversing multiple inner exceptions in the case of
This library provides classes for use in threading scenarios:
AsyncSynchronizationContext- A SynchronizationContext that uses the Task Parallel Library (TPL) to process callbacks asynchronously
|Product||Versions Compatible and additional computed target framework versions.|
|.NET||net5.0 was computed. net5.0-windows was computed. net6.0 is compatible. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 is compatible. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed.|
|.NET Core||netcoreapp3.0 was computed. netcoreapp3.1 was computed.|
|.NET Standard||netstandard2.1 is compatible.|
|.NET Framework||net462 is compatible. net463 was computed. net47 was computed. net471 was computed. net472 was computed. net48 was computed. net481 was computed.|
|MonoAndroid||monoandroid was computed.|
|MonoMac||monomac was computed.|
|MonoTouch||monotouch was computed.|
|Tizen||tizen60 was computed.|
|Xamarin.iOS||xamarinios was computed.|
|Xamarin.Mac||xamarinmac was computed.|
|Xamarin.TVOS||xamarintvos was computed.|
|Xamarin.WatchOS||xamarinwatchos was computed.|
NuGet packages (4)
Showing the top 4 NuGet packages that depend on Epiforge.Extensions.Components:
This package assists in operating with collections.
This package assists in operating with expressions.
This package assists in Windows-platform specific operations.
This package assists in developing WPF-based applications.
This package is not used by any popular GitHub repositories.
We added extension methods for getting the events, methods, and properties of a type, including interfaces and interface inheritance.