|
1 |
| -using BB84.Notifications.Interfaces; |
| 1 | +using BB84.Notifications.Interfaces.Commands; |
2 | 2 |
|
3 |
| -namespace BB84.Notifications; |
| 3 | +namespace BB84.Notifications.Commands; |
4 | 4 |
|
5 | 5 | /// <summary>
|
6 |
| -/// The async relay command class. |
| 6 | +/// The async action command class. |
7 | 7 | /// </summary>
|
8 | 8 | /// <param name="execute">The task to execute.</param>
|
9 | 9 | /// <param name="canExecute">The condition to execute.</param>
|
10 |
| -public sealed class AsyncRelayCommand(Func<Task> execute, Func<bool>? canExecute) : IAsyncRelayCommand |
| 10 | +public sealed class AsyncActionCommand(Func<Task> execute, Func<bool>? canExecute) : IAsyncActionCommand |
11 | 11 | {
|
12 | 12 | private bool _isExecuting;
|
13 | 13 |
|
14 | 14 | /// <summary>
|
15 |
| - /// Initializes a new instance of the <see cref="AsyncRelayCommand"/> class that can always execute. |
| 15 | + /// Initializes a new instance of the <see cref="AsyncActionCommand"/> class that can always execute. |
16 | 16 | /// </summary>
|
17 | 17 | /// <param name="execute">The task to execute.</param>
|
18 |
| - public AsyncRelayCommand(Func<Task> execute) : this(execute, null) |
| 18 | + public AsyncActionCommand(Func<Task> execute) : this(execute, null) |
19 | 19 | { }
|
20 | 20 |
|
21 | 21 | /// <inheritdoc/>
|
@@ -58,23 +58,23 @@ public void RaiseCanExecuteChanged()
|
58 | 58 | }
|
59 | 59 |
|
60 | 60 | /// <summary>
|
61 |
| -/// The async relay command class. |
| 61 | +/// The async action command class. |
62 | 62 | /// </summary>
|
63 | 63 | /// <remarks>
|
64 | 64 | /// For all commands that need a parameter.
|
65 | 65 | /// </remarks>
|
66 | 66 | /// <typeparam name="T">The generic type to work with.</typeparam>
|
67 | 67 | /// <param name="execute">The task to execute.</param>
|
68 | 68 | /// <param name="canExecute">The condition to execute.</param>
|
69 |
| -public sealed class AsyncRelayCommand<T>(Func<T, Task> execute, Func<T, bool>? canExecute) : IAsyncRelayCommand<T> |
| 69 | +public sealed class AsyncActionCommand<T>(Func<T, Task> execute, Func<T, bool>? canExecute) : IAsyncActionCommand<T> |
70 | 70 | {
|
71 | 71 | private bool _isExecuting;
|
72 | 72 |
|
73 | 73 | /// <summary>
|
74 |
| - /// Initializes a new instance of <see cref="AsyncRelayCommand{T}"/> class that can always execute. |
| 74 | + /// Initializes a new instance of <see cref="AsyncActionCommand{T}"/> class that can always execute. |
75 | 75 | /// </summary>
|
76 | 76 | /// <param name="execute">The task to execute.</param>
|
77 |
| - public AsyncRelayCommand(Func<T, Task> execute) : this(execute, null) |
| 77 | + public AsyncActionCommand(Func<T, Task> execute) : this(execute, null) |
78 | 78 | { }
|
79 | 79 |
|
80 | 80 | /// <inheritdoc/>
|
|
0 commit comments