Path: blob/main/third_party/closure-compiler/node-externs/process.js
6171 views
/*1* Copyright 2012 The Closure Compiler Authors.2*3* Licensed under the Apache License, Version 2.0 (the "License");4* you may not use this file except in compliance with the License.5* You may obtain a copy of the License at6*7* http://www.apache.org/licenses/LICENSE-2.08*9* Unless required by applicable law or agreed to in writing, software10* distributed under the License is distributed on an "AS IS" BASIS,11* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.12* See the License for the specific language governing permissions and13* limitations under the License.14*/1516/**17* @fileoverview Definitions for node's global process object. Depends on the stream module.18* @see http://nodejs.org/api/process.html19* @externs20* @author Daniel Wirtz <[email protected]>21*/2223/**24* @constructor25* @extends events.EventEmitter26*/27var process = function() {};2829/**30* @type {stream.ReadableStream}31*/32process.stdin;3334/**35* @type {stream.WritableStream}36*/37process.stdout;3839/**40* @type {stream.WritableStream}41*/42process.stderr;4344/**45* @type {Array.<string>}46*/47process.argv;4849/**50* @type {string}51*/52process.execPath;5354/**55*/56process.abort = function() {};5758/**59* @param {string} directory60*/61process.chdir = function(directory) {};6263/**64* @return {string}65* @nosideeffects66*/67process.cwd = function() {};6869/**70* @type {Object.<string,string>}71*/72process.env;7374/**75* @param {number=} code76*/77process.exit = function(code) {};7879/**80* @return {number}81* @nosideeffects82*/83process.getgid = function() {};8485/**86* @param {number} id87*/88process.setgid = function(id) {};8990/**91* @return {number}92* @nosideeffects93*/94process.getuid = function() {};9596/**97* @param {number} id98*/99process.setuid = function(id) {};100101/**102* @type {!string}103*/104process.version;105106/**107* @type {Object.<string,string>}108*/109process.versions;110111/**112* @type {Object.<string,*>}113*/114process.config;115116/**117* @param {number} pid118* @param {string=} signal119*/120process.kill = function(pid, signal) {};121122/**123* @type {number}124*/125process.pid;126127/**128* @type {string}129*/130process.title;131132/**133* @type {string}134*/135process.arch;136137/**138* @type {string}139*/140process.platform;141142/**143* @return {Object.<string,number>}144* @nosideeffects145*/146process.memoryUsage = function() {};147148/**149* @param {!function()} callback150*/151process.nextTick = function(callback) {};152153/**154* @param {number=} mask155*/156process.umask = function(mask) {};157158/**159* @return {number}160* @nosideeffects161*/162process.uptime = function() {};163164/**165* @return {number}166* @nosideeffects167*/168process.hrtime = function() {};169170/**171*/172process.binding = function(name) {};173174/**175* @type {number}176*/177process.exitCode;178179180