Status Request APIs for C and C++
Status Request APIs are used to retrieve the status of an API requested to the server, and to get the error number and a string containing the error details in case there is a request failure.
This page contains information about the Status Request APIs for C and C++, including the description and syntax, and the input, input types, input description, and input return values.
na_results_status
Prototype
int na_results_status(na_elem_t* elt);
Description
Gets the result status of an API invoked either by na_server_invoke() or na_server_invoke_elem().
Return value
◦
NA_OK on success
◦
NA_FAILED on failure
na_results_errno
Prototype
int na_results_errno(na_elem_t* elt);
Description
Gets the error number if an API invocation using either na_server_invoke() or na_server_invoke_elem() has failed.
This API is used to determine the error number when the status of API invocation is NA_FAILED.
Return value
◦
-1 if an API invocation using either na_server_invoke() or na_server_invoke_elem() is successful
◦
na_results_reason
Prototype
const char* na_results_reason(na_elem_t* elt);
Description
Gets the reason for failure in a string if an API invocation using either na_server_invoke() or na_server_invoke_elem() has failed.
This API is used to find the reason of the error when the status of API invocation is NA_FAILED.
Return value
◦
NULL if an API invocation using either na_server_invoke() or na_server_invoke_elem() is successful
◦
◦
Parent topic: C and C++ Core APIs

Was this topic helpful? Send comments to NetApp.