errorCodeEnum.js 3.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879
  1. /**
  2. * 实体通讯错误码定义
  3. */
  4. var ErrorCodeEnum = {
  5. Error_Succeed : 0,
  6. //date check category
  7. Error_DataCheck : 100, //mark the beginning for this category
  8. Error_Null : 101, //the error of a null pointer
  9. Error_Param : 102, //the error of a illegal parameter
  10. Error_Overflow : 103, //The length or range overflow
  11. Error_TooSmallBuffer : 104, // buffer too small
  12. Error_NotIntegrated : 105, //The package or result is not intergrated
  13. //Target being category
  14. Error_TargetBeing : 0x200,
  15. Error_NoTarget : 0x201, //request target is not exist
  16. Error_NoDefine : 0x202, //The class or object no define
  17. Error_NotImpl : 0x203, //the method has not implement yet
  18. Error_NotExist : 0x204, //not exist
  19. Error_Duplication : 0x205, //Duplicate action or object
  20. Error_Unregisted : 0x206, //exist but the object has not regist
  21. Error_AlreadyExist : 0x207, //already exist
  22. Error_MethodNotFound : 0x208, //method does not exist
  23. Error_Redirect : 0x209, // redirect indication
  24. //Entity state category
  25. Error_InvalidState : 0x300, //state is not valid for current call
  26. Error_NotInit : 0x301, //The target is not be initial
  27. Error_Paused : 0x302, //the access object is in Pause state
  28. Error_Stoped : 0x303, //the access object is in Stop state
  29. Error_Losted : 0x304, //the access object is in Lost state
  30. Error_Closed : 0x305, //opposite side in close state
  31. //Framework Task control category
  32. Error_TaskControl : 0x400,
  33. Error_Pending : 0x401, //The request in not finish
  34. Error_Cancel : 0x402, //The process is be cancel by framework
  35. Error_Break : 0x403, //The task has interrupt
  36. Error_NotMeetCondition : 0x404, //not meat run condition,run cancel
  37. Error_NoPrivilege : 0x405, //no privilege
  38. Error_MethodSignatureFailed : 0x406,//method signature failed
  39. //opposite side action category
  40. Error_PeerAction : 0x500,
  41. Error_PeerClose : 0x501, //peer close request
  42. Error_PeerIgnore : 0x502, //peer did not anwer before the ITransactionContext object release
  43. Error_PeerReject : 0x503, //The another side reject the request
  44. Error_PeerDelay : 0x504, //The tast can not run right now,will be deley to set time
  45. //process fail category
  46. Error_Process : 0x600,
  47. Error_NetBroken : 0x601, //the network is broken
  48. Error_UpdateFailed : 0x602, //system update failed
  49. Error_RegistryFailed : 0x603, //registry operation failed
  50. Error_IO : 0x604, //IO error(file reading/writing)
  51. Error_Readonly : 0x605, //The object can't be edit
  52. // ...
  53. Error_TimeOut : 0x700,
  54. Error_BlockTimeOut : 0x701, //WaitAnswer time out
  55. Error_ThreadTimeOut: 0x702, //Max Thread run time
  56. Error_QueueTimeOut : 0x703, //Tast wait time out in queue
  57. Error_ReplyTimeOut : 0x704, //The system max answer time
  58. // ...
  59. Error_Debug : 0xf00,
  60. Error_Assert: 0xf01,
  61. Error_Trace : 0xf02,
  62. Error_Bug : 0xf03, //bug detected
  63. /*
  64. // device error code x define at range 0x00010000 <= x <= 0x0001ffff
  65. //
  66. Error_Device_Begin = 0x00010000,
  67. //...... device error codes goes here
  68. Error_Device_End = 0x0001ffff,
  69. */
  70. Error_Unrecover : 0x70000000,
  71. Error_Resource : 0x70000001, //The system resource ec:memory/handle/space,do not retry,should restart system
  72. Error_NewProcess: 0x70000002, //start process failed
  73. Error_FailVerify: 0x70000003, //Signature verification failed of entity
  74. Error_Block : 0x70000004, //The thread block and the module hold
  75. Error_Exception : 0x70000005, //except throw
  76. Error_Unexpect : 0x7ffffffe, //the fail reason is not expect
  77. Error_IgnoreAll : 0x7fffffff, // for special internal usage only, user dont use this code
  78. };