Table of Contents

Class RDCoreNotificationHandler<TNotification>

Namespace
RDCore.SDK.Platform.Protocol
Assembly
RDCore.SDK.dll

The base class for a platform protocol JSON-RPC notification.

public abstract class RDCoreNotificationHandler<TNotification> : IJsonRpcNotificationHandler<TNotification>, IRequestHandler<TNotification>, IRequestHandler<TNotification, Unit>, IJsonRpcHandler where TNotification : IRequest

Type Parameters

TNotification

A serializable type representing the notification parameters.

Inheritance
RDCoreNotificationHandler<TNotification>
Implements
IRequestHandler<TNotification>
IRequestHandler<TNotification, Unit>
Inherited Members

Remarks

A [Method] attribute must be specified on the implementing class to map the handler to a specific platform protocol notification.

Methods

Handle(TNotification, CancellationToken)

Handles a request

public Task<Unit> Handle(TNotification request, CancellationToken cancellationToken)

Parameters

request TNotification

The request

cancellationToken CancellationToken

Cancellation token

Returns

Task<Unit>

Response from the request

HandleNotificationAsync(TNotification, CancellationToken)

protected abstract Task HandleNotificationAsync(TNotification request, CancellationToken token)

Parameters

request TNotification
token CancellationToken

Returns

Task