Skip to content
Snippets Groups Projects
Commit 5b944107 authored by Richard T. Carback III's avatar Richard T. Carback III
Browse files

Add event callback registration to the bindings

parent fd347973
Branches
Tags
3 merge requests!23Release,!13Hotfix/no host cooldown + return sende2e TS,!11Client Event Reporting API
///////////////////////////////////////////////////////////////////////////////
// Copyright © 2020 xx network SEZC //
// //
// Use of this source code is governed by a license that can be found in the //
// LICENSE file //
///////////////////////////////////////////////////////////////////////////////
package bindings
// RegisterEventCallback records the given function to receive
// ReportableEvent objects. It returns the internal index
// of the callback so that it can be deleted later.
func (c *Client) RegisterEventCallback(myFunc EventCallbackFunction) int {
return c.api.RegisterEventCallback(myFunc)
}
// UnregisterEventCallback deletes the callback identified by the
// index. It returns an error if it fails.
func (c *Client) UnregisterEventCallback(index int) error {
return c.api.UnregisterEventCallback(index)
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment