Interface IServerHandler

Common interface for callback handlers that establish a server side control presence for the client session.

Namespace: PushTechnology.ClientInterface.Client.Callbacks
Assembly: Diffusion.Client.dll
Syntax
public interface IServerHandler
Remarks

Caution

Deprecated since 6.7. This interface is only used by deprecated methods and will be removed in a future release.

Methods

OnClose()

Called if the handler is closed. The handler will be closed if the session is closed after the handler has been registered, or if the handler is unregistered using CloseAsync().

No further calls will be made for the handler.

Declaration
void OnClose()

OnError(ErrorReason)

Notification of a contextual error related to this handler. This is analogous to an unchecked exception being raised. Situations in which onError is called include the session being closed before the handler is registered, a communication timeout, or a problem with the provided parameters. No further calls will be made to this handler.

Declaration
void OnError(ErrorReason errorReason)
Parameters
Type Name Description
ErrorReason errorReason

A value representing the error; this can be one of the constants defined in ErrorReason, or a feature-specific reason.

OnRegistered(IRegistration)

Called when the handler has been successfully registered with the server.

A session can register at most one handler of each type. If there is already a handler registered the operation will fail, registeredHandler will be closed, and the session error handler will be notified. To change the handler, first call CloseAsync() for the previous handler.

Declaration
void OnRegistered(IRegistration registration)
Parameters
Type Name Description
IRegistration registration

A reference that allows the handler to be closed.

Back to top