Click or drag to resize
Akka.NETActReceiveAsyncT Method (FuncT, IActorContext, Task, PredicateT)
Registers an async handler for messages of the specified type T

Namespace:  Akka.Actor.Dsl
Assembly:  Akka (in Akka.dll) Version: 1.2.3.42 (1.2.3.42)
Syntax
public void ReceiveAsync<T>(
	Func<T, IActorContext, Task> handler,
	Predicate<T> shouldHandle = null
)

Parameters

handler
Type: SystemFuncT, IActorContext, Task
the message handler invoked on the incoming message
shouldHandle (Optional)
Type: SystemPredicateT
when not null, determines whether this handler should handle the message

Type Parameters

T
the type of the message

Implements

IActorDslReceiveAsyncT(FuncT, IActorContext, Task, PredicateT)
See Also