mirror of
https://github.com/ICDSystems/ICD.Common.Utils.git
synced 2026-04-12 12:07:05 +00:00
feat: Adding IGenericEventArgs<T> interface for convenience
This commit is contained in:
parent
29eb28b1f1
commit
8d753e1cf9
3 changed files with 15 additions and 1 deletions
|
|
@ -2,8 +2,11 @@
|
|||
|
||||
namespace ICD.Common.Utils.EventArguments
|
||||
{
|
||||
public class GenericEventArgs<T> : EventArgs
|
||||
public class GenericEventArgs<T> : EventArgs, IGenericEventArgs<T>
|
||||
{
|
||||
/// <summary>
|
||||
/// Gets the wrapped data associated with the event.
|
||||
/// </summary>
|
||||
public T Data { get; private set; }
|
||||
|
||||
/// <summary>
|
||||
|
|
|
|||
10
ICD.Common.Utils/EventArguments/IGenericEventArgs.cs
Normal file
10
ICD.Common.Utils/EventArguments/IGenericEventArgs.cs
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
namespace ICD.Common.Utils.EventArguments
|
||||
{
|
||||
public interface IGenericEventArgs<T>
|
||||
{
|
||||
/// <summary>
|
||||
/// Gets the wrapped data associated with the event.
|
||||
/// </summary>
|
||||
T Data { get; }
|
||||
}
|
||||
}
|
||||
|
|
@ -81,6 +81,7 @@
|
|||
<Compile Include="EventArguments\DateTimeEventArgs.cs" />
|
||||
<Compile Include="EventArguments\FloatEventArgs.cs" />
|
||||
<Compile Include="EventArguments\GenericEventArgs.cs" />
|
||||
<Compile Include="EventArguments\IGenericEventArgs.cs" />
|
||||
<Compile Include="EventArguments\IntEventArgs.cs" />
|
||||
<Compile Include="EventArguments\StringEventArgs.cs" />
|
||||
<Compile Include="EventArguments\UShortEventArgs.cs" />
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue