Interface IInteractiveListener<T>
Listener allowing to await next message.
Namespace: TehGM.Wolfringo.Utilities.Interactive
Assembly: Wolfringo.Utilities.Interactive.dll
Syntax
public interface IInteractiveListener<T>
where T : IWolfMessage
Type Parameters
| Name | Description |
|---|---|
| T | Type of message |
Methods
| Improve this Doc View SourceAwaitNextAsync(IWolfClient, CancellationToken)
Awaits next message of given type.
Declaration
Task<T> AwaitNextAsync(IWolfClient client, CancellationToken cancellationToken = default(CancellationToken))
Parameters
| Type | Name | Description |
|---|---|---|
| IWolfClient | client | Client to await message from. |
| System.Threading.CancellationToken | cancellationToken | Token that will cancel the awaiting. |
Returns
| Type | Description |
|---|---|
| System.Threading.Tasks.Task<T> | Next message. |