Defines, Structures, Typedefs, Functions.
More...
Detailed Description
Defines, Structures, Typedefs, Functions.
Macro Definition Documentation
#define CL_RMD_CALL_ASYNC (1<<0) |
0x0001 If you want to make a synchronous call, set this bit to 0.
When this bit is set to 1, it is an asynchronous call.
#define CL_RMD_DEFAULT_TIMEOUT 10000 |
Default timeout for the RMD call - 10 seconds QNX has a traffic shaper leaky bucket.
So have higher timeouts.
Typedef Documentation
Callback function pointer for the async RMD call.
- Parameters
-
retCode | The return code of the remote function or RMD return code. |
pCookie | The value that you passed when you made the RMD call. |
inMsgHdl | Input passed when making the call. |
outMsgHdl | This is the output from the remote server. You must "free" this pointer and ONLY this pointer. |
- Description:
- Callback function pointer for the asynchronous call. You need to free the output message only.
- See Also
- clRmdWithMsg()
This structure ClRmdAsyncOptionsT contains additional asynchronous call parameters.
It is used to pass these parameters.
Function Documentation
Invokes a Remote Function Call when the parameters are passed as messages.
- Header File:
- clRmdApi.h
- Parameters
-
remoteObjAddr | Address of the destination Object. |
funcId | Function Id to be executed. |
inMsgHdl | Created and freed by the caller except when CL_RMD_CALL_NON_PERSISTENT is set. In this case, RMD frees the message. NULL indicates no value is passed to the remote end by you. |
outMsgHdl | [out] Created and freed by the caller. If it is NULL and CL_RMD_CALL_NEED_REPLY flag is set, CL_RMD_RC(CL_ERR_INVALID_PARAM) will be returned. |
flags | It informs RMD to decide the type of call. You must specify the flag to indicate whether the call is Synchronous or Asynchronous, or whether Reply and Atmost Once semantics are required or not. |
options | Optional parameter that can be passed like- priority, timeout, cookie, retries, and callback function.
If it is NULL, default values be assumed. |
pAsyncOptions | This is to be passed only if the call made is asynchronous. In this parameter, optional parameters, like cookies and callback functions can be passed. |
- Return values
-
CL_OK | The API executed successfully |
- Return values
-
CL_ERR_NO_MEMORY | If system memory is no longer available |
CL_ERR_TIMEOUT | If reply is not received in specified time or an invalid IOC port id is passed |
CL_ERR_NULL_PTR | On passing a NULL pointer |
CL_INVALID_PARAMETER | On passing invalid parameters. |
CL_ERR_NOT_INITIALIZED | If RMD Library is not initialized. |
CL_ERR_NOT_IMPLEMENTED | If call type is not supported. It also returns some OS defined error codes. |
- Error Codes listed above are generated by RMD, therefore the return value contains the RMD Component Identifier.
- Return values
-
CL_EO_ERR_FUNC_NOT_REGISTERED | If the requested function is not registered. |
CL_EO_ERR_EO_SUSPENDED | If the remote EO is in suspended state. |
- Error codes listed above are generated by EO, therefore the return value contains the EO Component Identifier.
- Return values
-
CL_IOC_ERR_RECV_UNBLOCKED | If the receiver is unblocked. |
CL_IOC_ERR_HOST_UNREACHABLE | If an invalid node address is passed. |
CL_IOC_ERR_COMP_UNREACHABLE | If an invalid commport address is passed. |
CL_ERR_NOT_EXIST | If an invalid logical address is passed. |
- Error codes listed above are generated by IOC, therefore the return value contains the IOC Component Identifier.
- Description:
- This API is used to invoke a Remote Function Call. You must pass the the the following parameters.
- destination address, that is, the remote ObjectId where the function is exposed,
- the functionId to invoke
- input parameter in a message
- output message to receive the reply
- RMD specific flags
- RMD options
- RMD asynchronous calls options
- While making an asynchronous call, you need to pass options like- priority, timeout value, retries, cookie, and the callback function in a structure ClRmdAsyncOptions. But all the parameters are not mandatory for each and every call. As in case of synchronous call, cookie and callback function are not required to pass.
- The remote function is identifed by the remote object address and the Function ID.
- Library File:
- libClRmd