process.js 5.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. var promisify = require("./_promisify.js");
  2. var bind = function(c, f) { return f && f.bind(c); };
  3. Object.defineProperties(module.exports, {
  4. EventEmitter: { enumerable: true, value: process.EventEmitter },
  5. //_debugEnd: // skipping
  6. //_debugPause: // skipping
  7. //_debugProcess: // skipping
  8. //_events: // skipping
  9. //_eventsCount: // skipping
  10. //_exiting: // skipping
  11. //_fatalException: // skipping
  12. //_getActiveHandles: // skipping
  13. //_getActiveRequests: // skipping
  14. //_immediateCallback: // skipping
  15. //_kill: // skipping
  16. //_linkedBinding: // skipping
  17. //_maxListeners: // skipping
  18. //_rawDebug: // skipping
  19. //_startProfilerIdleNotifier: // skipping
  20. //_stopProfilerIdleNotifier: // skipping
  21. //_tickCallback: // skipping
  22. abort: { enumerable: true, value: bind(process, process.abort) },
  23. arch: { enumerable: true, get: function() { return process.arch; }, set: function(v) { process.arch = v; } },
  24. argv: { enumerable: true, get: function() { return process.argv; }, set: function(v) { process.argv = v; } },
  25. argv0: { enumerable: true, get: function() { return process.argv0; }, set: function(v) { process.argv0 = v; } },
  26. assert: { enumerable: true, value: bind(process, process.assert) },
  27. binding: { enumerable: true, value: bind(process, process.binding) },
  28. chdir: { enumerable: true, value: bind(process, process.chdir) },
  29. config: { enumerable: true, get: function() { return process.config; }, set: function(v) { process.config = v; } },
  30. cpuUsage: { enumerable: true, value: bind(process, process.cpuUsage) },
  31. cwd: { enumerable: true, value: bind(process, process.cwd) },
  32. debugPort: { enumerable: true, get: function() { return process.debugPort; }, set: function(v) { process.debugPort = v; } },
  33. dlopen: { enumerable: true, value: bind(process, process.dlopen) },
  34. domain: { enumerable: true, get: function() { return process.domain; }, set: function(v) { process.domain = v; } },
  35. emitWarning: { enumerable: true, value: bind(process, process.emitWarning) },
  36. env: { enumerable: true, get: function() { return process.env; }, set: function(v) { process.env = v; } },
  37. execArgv: { enumerable: true, get: function() { return process.execArgv; }, set: function(v) { process.execArgv = v; } },
  38. execPath: { enumerable: true, get: function() { return process.execPath; }, set: function(v) { process.execPath = v; } },
  39. exit: { enumerable: true, value: bind(process, process.exit) },
  40. features: { enumerable: true, get: function() { return process.features; }, set: function(v) { process.features = v; } },
  41. getegid: { enumerable: true, value: bind(process, process.getegid) },
  42. geteuid: { enumerable: true, value: bind(process, process.geteuid) },
  43. getgid: { enumerable: true, value: bind(process, process.getgid) },
  44. getgroups: { enumerable: true, value: bind(process, process.getgroups) },
  45. getuid: { enumerable: true, value: bind(process, process.getuid) },
  46. hasUncaughtExceptionCaptureCallback: { enumerable: true, value: bind(process, process.hasUncaughtExceptionCaptureCallback) },
  47. hrtime: { enumerable: true, value: bind(process, process.hrtime) },
  48. initgroups: { enumerable: true, value: bind(process, process.initgroups) },
  49. kill: { enumerable: true, value: bind(process, process.kill) },
  50. mainModule: { enumerable: true, get: function() { return process.mainModule; }, set: function(v) { process.mainModule = v; } },
  51. memoryUsage: { enumerable: true, value: bind(process, process.memoryUsage) },
  52. moduleLoadList: { enumerable: true, get: function() { return process.moduleLoadList; }, set: function(v) { process.moduleLoadList = v; } },
  53. nextTick: { enumerable: true, value: promisify(process, process.nextTick, 0) },
  54. openStdin: { enumerable: true, value: bind(process, process.openStdin) },
  55. pid: { enumerable: true, get: function() { return process.pid; }, set: function(v) { process.pid = v; } },
  56. platform: { enumerable: true, get: function() { return process.platform; }, set: function(v) { process.platform = v; } },
  57. ppid: { enumerable: true, get: function() { return process.ppid; }, set: function(v) { process.ppid = v; } },
  58. reallyExit: { enumerable: true, value: bind(process, process.reallyExit) },
  59. release: { enumerable: true, get: function() { return process.release; }, set: function(v) { process.release = v; } },
  60. setUncaughtExceptionCaptureCallback: { enumerable: true, value: bind(process, process.setUncaughtExceptionCaptureCallback) },
  61. setegid: { enumerable: true, value: bind(process, process.setegid) },
  62. seteuid: { enumerable: true, value: bind(process, process.seteuid) },
  63. setgid: { enumerable: true, value: bind(process, process.setgid) },
  64. setgroups: { enumerable: true, value: bind(process, process.setgroups) },
  65. setuid: { enumerable: true, value: bind(process, process.setuid) },
  66. stderr: { enumerable: true, get: function() { return process.stderr; }, set: function(v) { process.stderr = v; } },
  67. stdin: { enumerable: true, get: function() { return process.stdin; }, set: function(v) { process.stdin = v; } },
  68. stdout: { enumerable: true, get: function() { return process.stdout; }, set: function(v) { process.stdout = v; } },
  69. title: { enumerable: true, get: function() { return process.title; }, set: function(v) { process.title = v; } },
  70. umask: { enumerable: true, value: bind(process, process.umask) },
  71. uptime: { enumerable: true, value: bind(process, process.uptime) },
  72. version: { enumerable: true, get: function() { return process.version; }, set: function(v) { process.version = v; } },
  73. versions: { enumerable: true, get: function() { return process.versions; }, set: function(v) { process.versions = v; } },
  74. });