-
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #10 from FRACerqueira/v.1.0.2
V.1.0.2
- Loading branch information
Showing
24 changed files
with
646 additions
and
566 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
// ******************************************************************************************** | ||
// MIT LICENCE | ||
// The maintenance and evolution is maintained by the PipeAndFilter project under MIT license | ||
// ******************************************************************************************** | ||
|
||
namespace PipeFilterCore | ||
{ | ||
/// <summary> | ||
/// Represents commands for conditions. | ||
/// </summary> | ||
/// <typeparam name="T">Type of contract.</typeparam> | ||
public interface IPipeAndFilterTaskCondition<T>: IPipeAndFilterBuild<T> where T : class | ||
{ | ||
/// <summary> | ||
/// Add new pipe. | ||
/// </summary> | ||
/// <param name="command">The handler pipe to execute.</param> | ||
/// <param name="alias"> | ||
/// The unique alias for pipe. | ||
/// <br>If the alias is omitted, the alias will be the handler name followed by the reference quantity (if any).</br> | ||
/// <br>Alias is used to reference in another pipe.</br> | ||
/// </param> | ||
/// <returns><see cref="IPipeAndFilterAdd{T}"/></returns> | ||
IPipeAndFilterAdd<T> AddPipe(Func<EventPipe<T>, CancellationToken, Task> command, string? alias = null); | ||
|
||
/// <summary> | ||
/// Add new pipe aggregate tasks. | ||
/// </summary> | ||
/// <param name="command">The handler pipe aggregate to execute. | ||
/// <br>The handler command will run after all tasks are executed.</br> | ||
/// </param> | ||
/// <param name="alias"> | ||
/// The unique alias for pipe. | ||
/// <br>If the alias is omitted, the alias will be the handler name followed by the reference quantity (if any).</br> | ||
/// <br>Alias is used to reference in another pipe.</br> | ||
/// </param> | ||
/// <returns><see cref="IPipeAndFilterTasks{T}"/></returns> | ||
IPipeAndFilterTasks<T> AddPipeTasks(Func<EventPipe<T>, CancellationToken, Task> command, string? alias = null); | ||
|
||
|
||
/// <summary> | ||
/// Add new task (execution in parallel) through pipe. | ||
/// </summary> | ||
/// <param name="command">The handler task to execute.</param> | ||
/// <param name="nametask">The name for task (optional).</param> | ||
/// <returns><see cref="IPipeAndFilterTasks{T}"/></returns> | ||
IPipeAndFilterTasks<T> AddTask(Func<EventPipe<T>, CancellationToken, Task> command, string? nametask = null); | ||
|
||
/// <summary> | ||
/// Add new condition for task. | ||
/// </summary> | ||
/// <param name="condition">The handle condition to execute.</param> | ||
/// <param name="namecondition">The name for condition(optional).</param> | ||
/// <returns><see cref="IPipeAndFilterTaskCondition{T}"/></returns> | ||
IPipeAndFilterTaskCondition<T> WithCondition(Func<EventPipe<T>, CancellationToken, ValueTask<bool>> condition, string? namecondition = null); | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.