-
Notifications
You must be signed in to change notification settings - Fork 10
/
Copy pathmain.d.ts
206 lines (194 loc) · 3.1 KB
/
main.d.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
/**
* What is the default action for this signal when it is not handled.
*/
export type SignalAction = 'terminate' | 'core' | 'ignore' | 'pause' | 'unpause'
/**
* Which standard defined that signal.
*/
export type SignalStandard = 'ansi' | 'posix' | 'bsd' | 'systemv' | 'other'
/**
* Standard name of the signal, for example 'SIGINT'.
*/
export type SignalName =
| 'SIGHUP'
| 'SIGINT'
| 'SIGQUIT'
| 'SIGILL'
| 'SIGTRAP'
| 'SIGABRT'
| 'SIGIOT'
| 'SIGBUS'
| 'SIGEMT'
| 'SIGFPE'
| 'SIGKILL'
| 'SIGUSR1'
| 'SIGSEGV'
| 'SIGUSR2'
| 'SIGPIPE'
| 'SIGALRM'
| 'SIGTERM'
| 'SIGSTKFLT'
| 'SIGCHLD'
| 'SIGCLD'
| 'SIGCONT'
| 'SIGSTOP'
| 'SIGTSTP'
| 'SIGTTIN'
| 'SIGBREAK'
| 'SIGTTOU'
| 'SIGURG'
| 'SIGXCPU'
| 'SIGXFSZ'
| 'SIGVTALRM'
| 'SIGPROF'
| 'SIGWINCH'
| 'SIGIO'
| 'SIGPOLL'
| 'SIGINFO'
| 'SIGPWR'
| 'SIGSYS'
| 'SIGUNUSED'
| 'SIGRT1'
| 'SIGRT2'
| 'SIGRT3'
| 'SIGRT4'
| 'SIGRT5'
| 'SIGRT6'
| 'SIGRT7'
| 'SIGRT8'
| 'SIGRT9'
| 'SIGRT10'
| 'SIGRT11'
| 'SIGRT12'
| 'SIGRT13'
| 'SIGRT14'
| 'SIGRT15'
| 'SIGRT16'
| 'SIGRT17'
| 'SIGRT18'
| 'SIGRT19'
| 'SIGRT20'
| 'SIGRT21'
| 'SIGRT22'
| 'SIGRT23'
| 'SIGRT24'
| 'SIGRT25'
| 'SIGRT26'
| 'SIGRT27'
| 'SIGRT28'
| 'SIGRT29'
| 'SIGRT30'
| 'SIGRT31'
/**
* Code number of the signal, for example 2.
* While most number are cross-platform, some are different between different
* OS.
*/
export type SignalNumber =
| 1
| 2
| 3
| 4
| 5
| 6
| 7
| 8
| 9
| 10
| 11
| 12
| 13
| 14
| 15
| 16
| 17
| 18
| 19
| 20
| 21
| 22
| 23
| 24
| 25
| 26
| 27
| 28
| 29
| 30
| 31
| 34
| 35
| 36
| 37
| 38
| 39
| 40
| 41
| 42
| 43
| 44
| 45
| 46
| 47
| 48
| 49
| 50
| 51
| 52
| 53
| 54
| 55
| 56
| 57
| 58
| 59
| 60
| 61
| 62
| 63
| 64
export interface Signal {
/**
* Standard name of the signal, for example 'SIGINT'.
*/
name: SignalName
/**
* Code number of the signal, for example 2.
* While most number are cross-platform, some are different between different
* OS.
*/
number: SignalNumber
/**
* Human-friendly description for the signal, for example
* 'User interruption with CTRL-C'.
*/
description: string
/**
* Whether the current OS can handle this signal in Node.js using
* `process.on(name, handler)`. The list of supported signals is OS-specific.
*/
supported: boolean
/**
* What is the default action for this signal when it is not handled.
*/
action: SignalAction
/**
* Whether the signal's default action cannot be prevented.
* This is true for SIGTERM, SIGKILL and SIGSTOP.
*/
forced: boolean
/**
* Which standard defined that signal.
*/
standard: SignalStandard
}
/**
* Object whose keys are signal names and values are signal objects.
*/
export declare const signalsByName: { [SignalNameType in SignalName]: Signal }
/**
* Object whose keys are signal numbers and values are signal objects.
*/
export declare const signalsByNumber: {
[SignalNumberType in SignalNumber]: Signal
}