OrbbecSDK 2.5.5
OrbbecSDK: Software-Development-Kit for Orbbec 3D Cameras
Loading...
Searching...
No Matches
Error.h
Go to the documentation of this file.
1// Copyright (c) Orbbec Inc. All Rights Reserved.
2// Licensed under the MIT License.
3
8#pragma once
9
10#ifdef __cplusplus
11extern "C" {
12#endif
13
14#include "ObTypes.h"
15
26OB_EXPORT ob_error *ob_create_error(ob_status status, const char *message, const char *function, const char *args, ob_exception_type exception_type);
27
35
42OB_EXPORT const char *ob_error_get_message(const ob_error *error);
43
50OB_EXPORT const char *ob_error_get_function(const ob_error *error);
51
58OB_EXPORT const char *ob_error_get_args(const ob_error *error);
59
67
74
75// The following interfaces are deprecated and are retained here for compatibility purposes.
76#define ob_error_status ob_error_get_status
77#define ob_error_message ob_error_get_message
78#define ob_error_function ob_error_get_function
79#define ob_error_args ob_error_get_args
80#define ob_error_exception_type ob_error_get_exception_type
81
82#ifdef __cplusplus
83}
84#endif
OB_EXPORT ob_exception_type ob_error_get_exception_type(const ob_error *error)
Get the type of exception that caused the error.
OB_EXPORT void ob_delete_error(ob_error *error)
Delete the error object.
OB_EXPORT const char * ob_error_get_message(const ob_error *error)
Get the error message.
OB_EXPORT ob_error * ob_create_error(ob_status status, const char *message, const char *function, const char *args, ob_exception_type exception_type)
Create a new error object.
OB_EXPORT ob_status ob_error_get_status(const ob_error *error)
Get the error status.
OB_EXPORT const char * ob_error_get_args(const ob_error *error)
Get the error parameters.
OB_EXPORT const char * ob_error_get_function(const ob_error *error)
Get the name of the API function that caused the error.
#define OB_EXPORT
Definition Export.h:15
Provide structs commonly used in the SDK, enumerating constant definitions.
enum OBExceptionType ob_exception_type
enum OBStatus ob_status
The error class exposed by the SDK, users can get detailed error information according to the error.
Definition ObTypes.h:117