104 if (!successMessage.empty())
105 std::cout << successMessage << std::endl;
108 std::cout <<
"Error Code : " << status.
errorCode
void showError(const mmind::eye::ErrorStatus &status, const std::string &successMessage={})
Prints the error code and its description.
Definition ErrorStatus.h:101
Describes the types of errors.
Definition ErrorStatus.h:12
ErrorCode
Describes the error codes.
Definition ErrorStatus.h:16
@ MMIND_STATUS_PARAMETER_ERROR
Definition ErrorStatus.h:28
@ MMIND_STATUS_PROFILE_POST_PROCESS_ERROR
An error occurred while profile post process.
Definition ErrorStatus.h:54
@ MMIND_STATUS_INVALID_INPUT_ERROR
Definition ErrorStatus.h:33
@ MMIND_STATUS_NO_SUPPORT_ERROR
Definition ErrorStatus.h:22
@ MMIND_STATUS_FILE_IO_ERROR
Definition ErrorStatus.h:36
@ MMIND_STATUS_RESPONSE_PARSE_ERROR
It is error to parse the response from device.
Definition ErrorStatus.h:52
@ MMIND_STATUS_DEVICE_BUSY
Definition ErrorStatus.h:48
@ MMIND_STATUS_ACQUISITION_TRIGGER_WAIT
Data acquisition has not been started.
Definition ErrorStatus.h:46
@ MMIND_STATUS_REPLY_WITH_ERROR
The reply from the device contains errors.
Definition ErrorStatus.h:44
@ MMIND_STATUS_MESSAGE_CHANNEL_ERROR
Definition ErrorStatus.h:57
@ MMIND_HANDEYE_CALIBRATION_EXECUTION_ERROR
An error occurred while executing the hand-eye calibration.
Definition ErrorStatus.h:42
@ MMIND_STATUS_TIMEOUT_ERROR
Definition ErrorStatus.h:39
@ MMIND_STATUS_DUPLICATE_REGISTRATION
Definition ErrorStatus.h:60
@ MMIND_STATUS_DEVICE_OFFLINE
Device is offline. Network issue may be present.
Definition ErrorStatus.h:21
@ MMIND_STATUS_MESSAGE_CHANNEL_OCCUPPIED
Definition ErrorStatus.h:64
@ MMIND_STATUS_SUCCESS
Success.
Definition ErrorStatus.h:17
@ MMIND_STATUS_INVALID_CALLBACKFUNC
The registered callback function is invalid.
Definition ErrorStatus.h:50
@ MMIND_STATUS_NO_DATA_ERROR
The image data is empty. Some error may have occurred on the device.
Definition ErrorStatus.h:31
@ MMIND_STATUS_OUT_OF_RANGE_ERROR
Definition ErrorStatus.h:26
@ MMIND_STATUS_INVALID_DEVICE
Definition ErrorStatus.h:18
@ MMIND_STATUS_BUFFER_FULL
The image buffer is full.
Definition ErrorStatus.h:67
ErrorStatus()=default
Default constructor.
std::string errorDescription
Definition ErrorStatus.h:95
ErrorStatus(ErrorCode code, const std::string &message)
Constructor.
Definition ErrorStatus.h:77
ErrorCode errorCode
Definition ErrorStatus.h:90
bool isOK() const
Returns true if the operation succeeded.
Definition ErrorStatus.h:85