RPCCallStore

class kanzi::connect::RPCCallStore

Public Functions

RPCCallStore()

Constructor.

RPCTypes::CommHandle allocateHandle()

Allocates a unique handle to be used in communication.

Return

the unique handle. Quaranteed not to return 0 in any scenario.

bool completeBool(RPCTypes::CommHandle handle, int32_t rpcstatus, bool value)

Complete bool type of item.

Return

true if rpc operation was pending and got completed.

Parameters
  • handle: identifies the item to complete

  • rpcstatus: low layer status for completion

  • value: value to set.

bool completeFloat(RPCTypes::CommHandle handle, int32_t rpcstatus, float value)

Complete float type of item.

Return

true if rpc operation was pending and got completed.

Parameters
  • handle: identifies the item to complete

  • rpcstatus: low layer status for completion

  • value: value to set.

bool completeInt(RPCTypes::CommHandle handle, int32_t rpcstatus, int32_t value)

Complete int type of item.

Return

true if rpc operation was pending and got completed.

Parameters
  • handle: identifies the item to complete

  • rpcstatus: low layer status for completion

  • value: value to set.

bool completeString(RPCTypes::CommHandle handle, int32_t rpcstatus, string value)

Complete string type of item.

Return

true if rpc operation was pending and got completed.

Parameters
  • handle: identifies the item to complete

  • rpcstatus: low layer status for completion

  • value: value to set.

void completeTimedOut()

Completes all timed out RPC calls.

bool completeVoid(RPCTypes::CommHandle handle, int32_t rpcstatus)

Complete void type of item.

Return

true if rpc operation was pending and got completed.

Parameters
  • handle: identifies the item to complete

  • rpcstatus: low layer status for completion

bool contains(RPCTypes::CommHandle handle)

Checks whether response with provided handle is known.

Return

true

Parameters
  • handle: the identifier of the operation

void handleLinkBroken()

Called when underlying link that carries RPC methods.

void put(RPCResult<void> item)

Insert item to store.

Parameters
  • item: to insert

void put(RPCResult<int32_t> item)

Insert item to store.

Parameters
  • item: to insert

void put(RPCResult<string> item)

Insert item to store.

Parameters
  • item: to insert

void put(RPCResult<bool> item)

Insert item to store.

Parameters
  • item: to insert

void put(RPCResult<float> item)

Insert item to store.

Parameters
  • item: to insert