NRC_GetMesssage(int num, NRC_Messsage& msg)
Get the numth message in the queue
Get the numth message in the queue, the message will not be removed
Type
int =>Get the numth message in the queue
Return value | Description |
---|---|
0 | The function is called successfully |
-101 | Invalid input parameter |
-102 | The target object does not exist. This typically occurs when the system initialization is incomplete, and calling other functions may return this value |
-103 | The target object is currently in an inoperable state |
Parameter Option
Parameter | Type | Description |
---|---|---|
num | int | The number of the message to be obtained in the queue, the earliest message number is 1, and the value range is 0 < num <= NRC_GetMesssageSize() |
msg | NRC_Messsage& | The obtained message is returned through this parameter |
Sample code
NRC_Messsage& msg;
NRC_GetMesssage(1, msg);