Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
emscripten-core
GitHub Repository: emscripten-core/emscripten
Path: blob/main/third_party/closure-compiler/node-externs/util.js
6174 views
1
/*
2
* Copyright 2012 The Closure Compiler Authors.
3
*
4
* Licensed under the Apache License, Version 2.0 (the "License");
5
* you may not use this file except in compliance with the License.
6
* You may obtain a copy of the License at
7
*
8
* http://www.apache.org/licenses/LICENSE-2.0
9
*
10
* Unless required by applicable law or agreed to in writing, software
11
* distributed under the License is distributed on an "AS IS" BASIS,
12
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
* See the License for the specific language governing permissions and
14
* limitations under the License.
15
*/
16
17
/**
18
* @fileoverview Definitions for node's util module. Depends on the stream module.
19
* @see http://nodejs.org/api/util.html
20
* @see https://github.com/joyent/node/blob/master/lib/util.js
21
* @externs
22
* @author Daniel Wirtz <[email protected]>
23
*/
24
25
/**
26
BEGIN_NODE_INCLUDE
27
var util = require('util');
28
END_NODE_INCLUDE
29
*/
30
31
/**
32
* @type {Object.<string,*>}
33
*/
34
var util = {};
35
36
/**
37
* @param {string} format
38
* @param {...*} var_args
39
* @return {string}
40
* @nosideeffects
41
*/
42
util.format = function(format, var_args) {};
43
44
/**
45
* @param {string} string
46
*/
47
util.debug = function(string) {};
48
49
/**
50
* @param {...*} var_args
51
*/
52
util.error = function(var_args) {};
53
54
/**
55
* @param {...*} var_args
56
*/
57
util.puts = function(var_args) {};
58
59
/**
60
* @param {...*} var_args
61
*/
62
util.print = function(var_args) {};
63
64
/**
65
* @param {string} string
66
*/
67
util.log = function(string) {};
68
69
/**
70
* @param {*} object
71
* @param {{showHidden: (boolean|undefined),
72
* depth: (number|null|undefined),
73
* colors: (boolean|undefined),
74
* customInspect: (boolean|undefined)}=} options
75
* @return {string}
76
* @nosideeffects
77
*/
78
util.inspect;
79
80
/**
81
* @param {*} object
82
* @return {boolean}
83
* @nosideeffects
84
*/
85
util.isArray = function(object) {};
86
87
/**
88
* @param {*} object
89
* @return {boolean}
90
* @nosideeffects
91
*/
92
util.isRegExp = function(object) {};
93
94
/**
95
* @param {*} object
96
* @return {boolean}
97
* @nosideeffects
98
*/
99
util.isDate = function(object) {};
100
101
/**
102
* @param {*} object
103
* @return {boolean}
104
* @nosideeffects
105
*/
106
util.isError = function(object) {};
107
108
/**
109
* @param {stream.ReadableStream} readableStream
110
* @param {stream.WritableStream} writableStream
111
* @param {function(...)=} callback
112
* @deprecated
113
*/
114
util.pump = function(readableStream, writableStream, callback) {};
115
116
/**
117
* @param {Function} constructor
118
* @param {Function} superConstructor
119
*/
120
util.inherits = function(constructor, superConstructor) {};
121
122