EOS_P2P_AddNotifyPeerConnectionClosed

EOS API reference page for EOS_P2P_AddNotifyPeerConnectionClosed

This function is part of the P2P Interface.

Remarks

Listen for when a previously opened connection is closed.

Return Value

A valid notification ID if successfully bound, or EOS_INVALID_NOTIFICATIONID otherwise

Parameters

Parameter Type And Name

Usage Information

EOS_HP2P Handle

const EOS_P2P_AddNotifyPeerConnectionClosedOptions* Options

Information about who would like notifications about closed connections, and for which socket

void* ClientData

This value is returned to the caller when ConnectionClosedHandler is invoked

EOS_P2P_OnRemoteConnectionClosedCallback ConnectionClosedHandler

The callback to be fired when we an open connection has been closed

This function enables your callback (the ConnectionClosedHandler parameter) to respond to events that happen on the back-end service. Remember to remove your callback function when it is no longer needed.

Callback Function Information

Because this function is asynchronous, it employs a callback of type EOS_P2P_OnRemoteConnectionClosedCallback to report the results of its operation.

Callback Remarks

Callback for information related to open connections being closed.

Callback Parameters

Parameter Type And Name

Usage Information

const EOS_P2P_OnRemoteConnectionClosedInfo* Data

Related API Members

Tags