#ifndef DPSDK_DPSDKERROR_H
#define DPSDK_DPSDKERROR_H

// General error[-99£¬0]
#define	DPSDK_SUCCESS						0				// Successful
#define DPSDK_FAILED						-1				// Failed
#define	DPSDK_UNKNOWN_ERROR			        -2		        // Unknown error
#define	DPSDK_FUNCTION_CALL_ERROR			-3		        // Internal function calling error
#define	DPSDK_INVAILD_PARAM					-4			    // Illegal parameter
#define DPSDK_NO_INIT						-5				// System uninitialized
#define DPSDK_USER_LOGINED					-6				// User is logged in
#define DPSDK_USER_INVALID					-7				// Invalid user. User session ID is invalid
#define DPSDK_USER_NOLOGINED				-8				// User not logged in
#define DPSDK_BUFFER_NOT_ENOUGH				-9				// Buffer insufficient
#define DPSDK_MQ_INITIALIZD					-10				// MQ initialized
#define DPSDK_INVALID_DATA					-11				// Invalid data
#define DPSDK_MALLOC_FAILED					-12				// Memory distribution failed
#define DPSDK_XML_INVALID					-13				// Invalid XML data
#define DPSDK_SERVER_TYPE_UNMATCH			-14				// The Service type of login is mismatching
#define DPSDK_NO_PLUGIN_INFO				-15				// no plugin info
#define DPSDK_ABNORMAL_NETWORK              -18				// network abnormal
#define DPSDK_GETSYSVERSION_FAILED			-20				// get system version failed
#define DPSDK_NOTEXISTVIMSSYSTEM			-30				// not exist VIMS System

#define DPSDK_GM_AUTH_FAILED				-31				// 35114 auth fail
#define DPSDK_MEDIA_HAS_STOPPED				-116			// Stop play in advance
#define DPSDK_GM_GET_NO_DEVICE				-32				// get no device
#define DPSDK_GM_PIN_ERROR					-33				// PIN wrong
#define DPSDK_35114C_AUTH_FAILED			-34				// 35114C auth fail
#define DPSDK_NET_UNAVAILABLE				-22				// Network unavailable

// Rest error code[-119, -100]
#define DPSDK_REST_REQUEST_TIMEOUT          -101			// Rest request timeout. This error code keeps the same as that inside Rest
#define DPSDK_REST_CONNECT_SERVER_FAILED    -103			// Link service failed
#define DPSDK_REST_URL_TIMEOUT				-104			// Rest request video url timeout. This error code keeps the same as that inside Rest
#define DPSDK_REST_RET_CERTFAILED			-105			// CA Certificate verification failed     Attention:HW old error code -105

#define DPSDK_REALPLAY_WITHOUT_STREAMRIGHT	-117			// Real request fail

// Preview error [-299£¬-200]
#define DPSDK_INVAILD_MEDIA_SESSIONID		-200			// Invalid media session ID (including preview, playback, intercom)
#define DPSDK_OPEN_SOUND_FAILED				-201			// Open audio failed
#define	DPSDK_TALKING_WITH_OTHER			-202			// Open audio failed. In intercom with other device
#define DPSDK_MEDIA_TYPE_UNMATCH			-203			// Media type mismatching
#define DPSDK_INVAILD_VAXPLAYER_INSTANCE	-204			// VaxPlayer is null when client will open audio

// Talk error[-349£¬-300]
#define DPSDK_TALK_PARAM_UNMATCH			-300			// Intercom parameter mismatching

// RRSPSDK error code[-499, -400]
#define DPSDK_RTSP_UDP_LISTEN_FAILED		-400			// UDP monitor failed
#define DPSDK_RTSP_CONNECT_SERVER_FAILED	-401			// Link service failed
#define DPSDK_RTSP_SENDDATA_FAILED			-402			// Data transmission failed
#define DPSDK_RTSP_COMMAND_CANCELED			-403			// Order is cancelled
#define DPSDK_RTSP_PORT_PARSE_FAILED		-404			// Port analysis failed
#define DPSDK_RTSP_SETUP_TIMEOUT			-405			// RTSP setup timeout
#define DPSDK_RTSP_PLAY_TIMEOUT				-406			// RTSP play timeout
#define DPSDK_RTSP_STREAM_TIMEOUT			-407			// RTSP receive video stream timeout

//Sip error code 
#define DPSDK_SIP_SCS_DATA_PARSE_ERROR		-500			// SCS data analysis failed
#define DPSDK_SIP_COMMAND_CANCELED			-501			// Order is cancelled


#define DPSDK_NEWCLIENT_OLDPLATFORM			-601			//Client version and platform version do not match.

#define DPSDK_UPGRADE_HISTORY_DATA			-701			//History data upgrade

#define DPSDK_USER_HAS_NO_AUTHORIZATION     1103 
#define DPSDK_SERVER_DATA_ERROR				3101			//The service return data has an error or is false.
#define DPSDK_SERVER_NO_ROECORD				3100			//Query Center Record Failed.

#define DPSDK_USER_LAST_CHANCE      2001 
#define DPSDK_USER_LOCKED			2002 

#define DPSDK_EVO_VERIFYCODE_ERROR			28110100
#define DPSDK_EVO_PWD_ERROR					28110009
#define DPSDK_EVO_USER_LOCKED				28110010
#define DPSDK_EVO_USER_NO_REUSE				28110053		// user is no reuse
#define DPSDK_EVO_MAC_NO_AUTHORIZE          28110090        // user is no anthorize
#define DPSDK_EVO_EXPORT_NUM_TOO_LARGE		26040009		// alarm log export num too large
#define DPSDK_EVO_EXPORT_OUT_OF_BOUND		99020026        // array index out of bound

#define DPSDK_LIMIT_FLOW_VIDEO				 300			// video limit flow
#define DPSDK_LIMIT_FLOW_VIDEO_NEW			 101866		    // video limit flow

#define DPSDK_FIRST_LOGIN_RESET_PWD		110002 
#define DPSDK_USER_FIRST_RESET_PASSWORD		110003

#define DPSDK__PREVIEW_NO_PERIOD_RIGHT			3208			// No Preview Period right
#define DPSDK_DOWNLOAD_ENCRYPT_USER_ERRORCODE 20434

#endif // _DPSDK_DPSDKERROR_H_
