GeezerVison is showing github.com — typings: share AsyncWrap and HandleWrap types · nodejs/node@7c62da0
File tree
Expand file treeCollapse file tree
Open diff view settings
Expand file treeCollapse file tree
Open diff view settings
Collapse file
Copy file name to clipboardExpand all lines: typings/internalBinding/async_wrap.d.ts +7Lines changed: 7 additions & 0 deletions | Original file line number | Diff line number | Diff line change |
|---|
|
1 | 1 | import { owner_symbol } from './symbols'; |
2 | 2 |
|
| 3 | +export interface AsyncWrap { |
| 4 | + getAsyncId(): number; |
| 5 | + asyncReset(resource: object, executionAsyncId?: number): void; |
| 6 | + getAsyncContextFrameForDebuggingOnly(): unknown; |
| 7 | + getProviderType(): number; |
| 8 | +} |
| 9 | + |
3 | 10 | declare namespace InternalAsyncWrapBinding { |
4 | 11 | interface Resource { |
5 | 12 | [owner_symbol]?: PublicResource; |
|
Collapse file
Copy file name to clipboard +8Lines changed: 8 additions & 0 deletions | Original file line number | Diff line number | Diff line change |
|---|
|
| 1 | +import type { AsyncWrap } from './async_wrap'; |
| 2 | + |
| 3 | +export interface HandleWrap extends AsyncWrap { |
| 4 | + close(callback?: () => void): void; |
| 5 | + hasRef(): boolean; |
| 6 | + ref(): void; |
| 7 | + unref(): void; |
| 8 | +} |
Collapse file
Copy file name to clipboardExpand all lines: typings/internalBinding/signal_wrap.d.ts +4-4Lines changed: 4 additions & 4 deletions | Original file line number | Diff line number | Diff line change |
|---|
|
| 1 | +import type { HandleWrap } from './handle_wrap'; |
| 2 | + |
1 | 3 | declare namespace InternalSignalWrapBinding { |
2 | 4 | class Signal { |
3 | 5 | constructor(); |
4 | 6 | onsignal?: (signum: number) => void; |
5 | 7 | start(signum: number): number | undefined; |
6 | 8 | stop(): number; |
7 | | - close(callback?: () => void): void; |
8 | | - hasRef(): boolean; |
9 | | - ref(): void; |
10 | | - unref(): void; |
11 | 9 | } |
| 10 | + |
| 11 | + interface Signal extends HandleWrap {} |
12 | 12 | } |
13 | 13 |
|
14 | 14 | export interface SignalWrapBinding { |
|
Collapse file
Copy file name to clipboardExpand all lines: typings/internalBinding/watchdog.d.ts +4-4Lines changed: 4 additions & 4 deletions | Original file line number | Diff line number | Diff line change |
|---|
|
| 1 | +import type { HandleWrap } from './handle_wrap'; |
| 2 | + |
1 | 3 | declare namespace InternalWatchdogBinding { |
2 | 4 | class TraceSigintWatchdog { |
3 | 5 | constructor(); |
4 | 6 | start(): void; |
5 | 7 | stop(): void; |
6 | | - close(callback?: () => void): void; |
7 | | - hasRef(): boolean; |
8 | | - ref(): void; |
9 | | - unref(): void; |
10 | 8 | } |
| 9 | + |
| 10 | + interface TraceSigintWatchdog extends HandleWrap {} |
11 | 11 | } |
12 | 12 |
|
13 | 13 | export interface WatchdogBinding { |
|