Skip to content

Commit

Permalink
Rename event args -> event data
Browse files Browse the repository at this point in the history
  • Loading branch information
Banane9 committed Apr 11, 2024
1 parent 059aadd commit 4a48eef
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 13 deletions.
4 changes: 2 additions & 2 deletions MonkeyLoader/Events/IEvent.cs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
namespace MonkeyLoader.Events
{
/// <summary>
/// Defines the interface for cancelable events with a
/// Defines the interface for cancelable event data with a
/// <see cref="IEvent{TTarget}.Target">target object</see> that's the focus of the event.
/// </summary>
/// <inheritdoc/>
Expand All @@ -24,7 +24,7 @@ public interface ICancelableEvent<out TTarget> : IEvent<TTarget>
}

/// <summary>
/// Defines the interface for events with a
/// Defines the interface for event data with a
/// <see cref="Target">target object</see> that's the focus of the event.
/// </summary>
/// <typeparam name="TTarget">The type of the target object that is the focus of the event.</typeparam>
Expand Down
14 changes: 7 additions & 7 deletions MonkeyLoader/Events/IEventHandler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -21,15 +21,15 @@ public interface ICancelableEventHandler<in TEvent, out TTarget> : IPrioritizabl
public bool SkipCanceled { get; }

/// <summary>
/// Handles the given cancelable event.
/// Handles the given cancelable event based on its data.
/// </summary>
/// <remarks>
/// When this method sets <c><paramref name="eventArgs"/>.<see cref="ICancelableEvent{TTarget}.Canceled">Canceled</see>
/// When this method sets <c><paramref name="eventData"/>.<see cref="ICancelableEvent{TTarget}.Canceled">Canceled</see>
/// = true</c>, the default action should be prevented from happening and further
/// <see cref="ICancelableEventHandler{TEvent, TTarget}">event handlers</see> may be skipped.
/// </remarks>
/// <param name="eventArgs">An object containing all the relevant information for the event.</param>
public void Handle(TEvent eventArgs);
/// <param name="eventData">An object containing all the relevant information for the event.</param>
public void Handle(TEvent eventData);
}

/// <summary>
Expand All @@ -41,9 +41,9 @@ public interface IEventHandler<in TEvent, out TTarget> : IPrioritizable
where TEvent : IEvent<TTarget>
{
/// <summary>
/// Handles the given event.
/// Handles the given event based on its data.
/// </summary>
/// <param name="eventArgs">An object containing all the relevant information for the event.</param>
public void Handle(TEvent eventArgs);
/// <param name="eventData">An object containing all the relevant information for the event.</param>
public void Handle(TEvent eventData);
}
}
8 changes: 4 additions & 4 deletions MonkeyLoader/Events/IEventSource.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,17 +11,17 @@ namespace MonkeyLoader.Events
/// </summary>
/// <typeparam name="TEvent">The type representing the event arguments.</typeparam>
/// <typeparam name="TTarget">The type of the target objects that are the focus of the events.</typeparam>
/// <param name="eventArgs">An object containing all the relevant information for the events, including canceling the action.</param>
public delegate void CancelableEventDispatching<in TEvent, in TTarget>(TEvent eventArgs)
/// <param name="eventData">An object containing all the relevant information for the events, including canceling the action.</param>
public delegate void CancelableEventDispatching<in TEvent, in TTarget>(TEvent eventData)
where TEvent : class, ICancelableEvent<TTarget>;

/// <summary>
/// Delegate for the <see cref="IEventSource{TEvent, TTarget}.Dispatching"/> event.
/// </summary>
/// <typeparam name="TEvent">The type representing the event arguments.</typeparam>
/// <typeparam name="TTarget">The type of the target objects that are the focus of the events.</typeparam>
/// <param name="eventArgs">An object containing all the relevant information for the events.</param>
public delegate void EventDispatching<in TEvent, in TTarget>(TEvent eventArgs)
/// <param name="eventData">An object containing all the relevant information for the events.</param>
public delegate void EventDispatching<in TEvent, in TTarget>(TEvent eventData)
where TEvent : class, IEvent<TTarget>;

/// <summary>
Expand Down

0 comments on commit 4a48eef

Please sign in to comment.