summaryrefslogtreecommitdiff
path: root/cli/dts/lib.deno.unstable.d.ts
diff options
context:
space:
mode:
authorBartek IwaƄczuk <biwanczuk@gmail.com>2022-02-27 15:18:30 +0100
committerGitHub <noreply@github.com>2022-02-27 15:18:30 +0100
commit7e3d9084b69d12119b2ad6ef7ac2681e66e36aa0 (patch)
tree623cc4785c7fc18f91cf9a51763e5517a2aca640 /cli/dts/lib.deno.unstable.d.ts
parenta65ce33fabb44bb2d9ed04773f7f334ed9c9a6b5 (diff)
feat: Add Deno.TcpConn class, change return type from Deno.connect (#13714)
Diffstat (limited to 'cli/dts/lib.deno.unstable.d.ts')
-rw-r--r--cli/dts/lib.deno.unstable.d.ts20
1 files changed, 4 insertions, 16 deletions
diff --git a/cli/dts/lib.deno.unstable.d.ts b/cli/dts/lib.deno.unstable.d.ts
index 08b3ca80c..221ecee60 100644
--- a/cli/dts/lib.deno.unstable.d.ts
+++ b/cli/dts/lib.deno.unstable.d.ts
@@ -1049,7 +1049,10 @@ declare namespace Deno {
*
* Requires `allow-net` permission for "tcp" and `allow-read` for "unix". */
export function connect(
- options: ConnectOptions | UnixConnectOptions,
+ options: ConnectOptions,
+ ): Promise<TcpConn>;
+ export function connect(
+ options: UnixConnectOptions,
): Promise<Conn>;
export interface ConnectTlsOptions {
@@ -1066,21 +1069,6 @@ declare namespace Deno {
alpnProtocols?: string[];
}
- export interface Conn {
- /**
- * **UNSTABLE**: new API, see https://github.com/denoland/deno/issues/13617.
- *
- * Enable/disable the use of Nagle's algorithm. Defaults to true.
- */
- setNoDelay(nodelay?: boolean): void;
- /**
- * **UNSTABLE**: new API, see https://github.com/denoland/deno/issues/13617.
- *
- * Enable/disable keep-alive functionality.
- */
- setKeepAlive(keepalive?: boolean): void;
- }
-
export interface TlsHandshakeInfo {
/** **UNSTABLE**: new API, yet to be vetted.
*