daeError.h 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. /*
  2. * Copyright 2006 Sony Computer Entertainment Inc.
  3. *
  4. * Licensed under the MIT Open Source License, for details please see license.txt or the website
  5. * http://www.opensource.org/licenses/mit-license.php
  6. *
  7. */
  8. #ifndef __DAE__ERROR__
  9. #define __DAE__ERROR__
  10. #include <dae/daePlatform.h>
  11. /** Success */
  12. #define DAE_OK 0
  13. /** Fatal Error, should never be returned unless there is a bug in the library. */
  14. #define DAE_ERR_FATAL -1
  15. /** Call invalid, the combination of parameters given is invalid. */
  16. #define DAE_ERR_INVALID_CALL -2
  17. /** Generic error */
  18. #define DAE_ERROR -3
  19. /** IO error, the file hasn't been found or there is a problem with the IO plugin. */
  20. #define DAE_ERR_BACKEND_IO -100
  21. /** The IOPlugin backend wasn't able to successfully validate the data. */
  22. #define DAE_ERR_BACKEND_VALIDATION -101
  23. /** The IOPlugin tried to write to a file that already exists and the "replace" parameter was set to false */
  24. #define DAE_ERR_BACKEND_FILE_EXISTS -102
  25. /** Error in the syntax of the query. */
  26. #define DAE_ERR_QUERY_SYNTAX -200
  27. /** No match to the search criteria. */
  28. #define DAE_ERR_QUERY_NO_MATCH -201
  29. /** A document with that name already exists. */
  30. #define DAE_ERR_COLLECTION_ALREADY_EXISTS -202
  31. /** A document with that name does not exist. */
  32. #define DAE_ERR_COLLECTION_DOES_NOT_EXIST -203
  33. /** Function is not implemented. */
  34. #define DAE_ERR_NOT_IMPLEMENTED -1000
  35. /** Gets the ASCII error string.
  36. * @param errorCode Error code returned by a function of the API.
  37. * @return Returns an English string describing the error.
  38. */
  39. DLLSPEC const char *daeErrorString(int errorCode);
  40. #endif //__DAE__ERROR__