Base module

Action

Default action type for executing synchronized callbacks.

#include <icy/ipc.h>

struct Action

Defined in src/base/include/icy/ipc.h:33

Public Attributes

ReturnNameDescription
CallbacktargetThe callable to invoke when the action is dispatched.
void *argOptional opaque pointer passed to the callback.
std::stringdataOptional string payload passed to the callback.

target

Callback target

Type: Callback

Defined in src/base/include/icy/ipc.h:37

The callable to invoke when the action is dispatched.


arg

void * arg

Defined in src/base/include/icy/ipc.h:38

Optional opaque pointer passed to the callback.


data

std::string data

Defined in src/base/include/icy/ipc.h:39

Optional string payload passed to the callback.

Public Methods

ReturnNameDescription
Action inlineConstructs an Action with the given callback, optional argument, and optional data.

Action

inline

inline Action(Callback target, void * arg = nullptr, const std::string & data = "")

Defined in src/base/include/icy/ipc.h:45

Constructs an Action with the given callback, optional argument, and optional data.

Parameters

ParameterTypeDescription
targetCallbackCallback to invoke on dispatch.
argvoid *Opaque pointer passed to the callback (default: nullptr).
dataconst std::string &String payload passed to the callback (default: empty).

Public Types

NameDescription
Callback

Callback

using Callback = std::function< void(const Action &)>

Type: std::function< void(const Action &)>

Defined in src/base/include/icy/ipc.h:35