diff options
Diffstat (limited to 'ext/net/lib.deno_net.d.ts')
-rw-r--r-- | ext/net/lib.deno_net.d.ts | 32 |
1 files changed, 29 insertions, 3 deletions
diff --git a/ext/net/lib.deno_net.d.ts b/ext/net/lib.deno_net.d.ts index a7ed95bae..c6a771bc0 100644 --- a/ext/net/lib.deno_net.d.ts +++ b/ext/net/lib.deno_net.d.ts @@ -69,7 +69,12 @@ declare namespace Deno { readonly localAddr: Addr; /** The remote address of the connection. */ readonly remoteAddr: Addr; - /** The resource ID of the connection. */ + /** + * The resource ID of the connection. + * + * @deprecated Use {@linkcode Deno.Conn} instance methods instead. + * {@linkcode Deno.Conn.rid} will be removed in Deno 2.0. + */ readonly rid: number; /** Shuts down (`shutdown(2)`) the write side of the connection. Most * callers should just use `close()`. */ @@ -103,6 +108,13 @@ declare namespace Deno { * not happened yet. Calling this method is optional; the TLS handshake * will be completed automatically as soon as data is sent or received. */ handshake(): Promise<TlsHandshakeInfo>; + /** + * The resource ID of the connection. + * + * @deprecated Use {@linkcode Deno.TlsConn} instance methods instead. + * {@linkcode Deno.TlsConn.rid} will be removed in Deno 2.0. + */ + readonly rid: number; } /** @category Network */ @@ -260,6 +272,13 @@ declare namespace Deno { setNoDelay(noDelay?: boolean): void; /** Enable/disable keep-alive functionality. */ setKeepAlive(keepAlive?: boolean): void; + /** + * The resource ID of the connection. + * + * @deprecated Use {@linkcode Deno.Conn} instance methods instead. + * {@linkcode Deno.Conn.rid} will be removed in Deno 2.0. + */ + readonly rid: number; } /** @category Network */ @@ -269,8 +288,15 @@ declare namespace Deno { } /** @category Network */ - // deno-lint-ignore no-empty-interface - export interface UnixConn extends Conn {} + export interface UnixConn extends Conn { + /** + * The resource ID of the connection. + * + * @deprecated Use {@linkcode Deno.UnixConn} instance methods instead. + * {@linkcode Deno.UnixConn.rid} will be removed in Deno 2.0. + */ + readonly rid: number; + } /** Connects to the hostname (default is "127.0.0.1") and port on the named * transport (default is "tcp"), and resolves to the connection (`Conn`). |