Show / Hide Table of Contents

Interface IMessageHandler<TMessage>

Application service for handling requests.

Inherited Members
IMessageHandler.ProcessAsync(IMessage, IMessagingContext, CancellationToken)
System.IDisposable.Dispose()
Namespace: Kephas.Messaging
Assembly: Kephas.Messaging.dll
Syntax
[AppServiceContract(ContractType = typeof(IMessageHandler), AllowMultiple = true, MetadataAttributes = new Type[]{typeof(MessageHandlerAttribute)})]
public interface IMessageHandler<in TMessage> : IMessageHandler, IDisposable
Type Parameters
Name Description
TMessage

The type of the message.

Methods

| Improve this Doc View Source

ProcessAsync(TMessage, IMessagingContext, CancellationToken)

Processes the provided message asynchronously and returns a response promise.

Declaration
Task<IMessage> ProcessAsync(TMessage message, IMessagingContext context, CancellationToken token)
Parameters
Type Name Description
TMessage message

The message to be handled.

IMessagingContext context

The processing context.

System.Threading.CancellationToken token

The cancellation token.

Returns
Type Description
System.Threading.Tasks.Task<IMessage>

The response promise.

Extension Methods

DynamicObjectExtensions.SetPropertyValue(Object, String, Object)
DynamicObjectExtensions.TrySetPropertyValue(Object, String, Object)
DynamicObjectExtensions.GetPropertyValue(Object, String)
DynamicObjectExtensions.TryGetPropertyValue(Object, String, out Object)
DynamicObjectExtensions.GetRuntimeTypeInfo(Object)
DynamicObjectExtensions.ToDynamic(Object)
DynamicObjectExtensions.ToExpando(Object)
BehaviorValue.ToBehaviorValue<TValue>(TValue)
CollectionExtensions.AddRange<T, TItem>(T, IEnumerable<TItem>)
LoggingExtensions.GetLogger(Object, IContext)
TypeExtensions.GetAbstractType(Object)
TypeExtensions.GetAbstractTypeInfo(Object)
ReflectionHelper.GetTypeInfo(Object)
EntityEntryExtensions.TryGetAttachedEntityEntry(Object)
  • Improve this Doc
  • View Source
Back to top Generated by DocFX