Skip to main content
Server.prototype.once - tls - Node documentation
method Server.prototype.once

Usage in Deno

import { Server } from "node:tls";
Server.prototype.once(
event: string,
listener: (...args: any[]) => void,
): this

Parameters

event: string
listener: (...args: any[]) => void

Return Type

this
Server.prototype.once(
event: "tlsClientError",
listener: (
err: Error,
tlsSocket: TLSSocket,
) => void
,
): this

Parameters

event: "tlsClientError"
listener: (
err: Error,
tlsSocket: TLSSocket,
) => void

Return Type

this
Server.prototype.once(
event: "newSession",
listener: (
sessionId: Buffer,
sessionData: Buffer,
callback: () => void,
) => void
,
): this

Parameters

event: "newSession"
listener: (
sessionId: Buffer,
sessionData: Buffer,
callback: () => void,
) => void

Return Type

this
Server.prototype.once(
event: "OCSPRequest",
listener: (
certificate: Buffer,
issuer: Buffer,
callback: (
err: Error | null,
resp: Buffer,
) => void
,
) => void
,
): this

Parameters

event: "OCSPRequest"
listener: (
certificate: Buffer,
issuer: Buffer,
callback: (
err: Error | null,
resp: Buffer,
) => void
,
) => void

Return Type

this
Server.prototype.once(
event: "resumeSession",
listener: (
sessionId: Buffer,
callback: (
err: Error | null,
sessionData: Buffer | null,
) => void
,
) => void
,
): this

Parameters

event: "resumeSession"
listener: (
sessionId: Buffer,
callback: (
err: Error | null,
sessionData: Buffer | null,
) => void
,
) => void

Return Type

this
Server.prototype.once(
event: "secureConnection",
listener: (tlsSocket: TLSSocket) => void,
): this

Parameters

event: "secureConnection"
listener: (tlsSocket: TLSSocket) => void

Return Type

this
Server.prototype.once(
event: "keylog",
listener: (
line: Buffer,
tlsSocket: TLSSocket,
) => void
,
): this

Parameters

event: "keylog"
listener: (
line: Buffer,
tlsSocket: TLSSocket,
) => void

Return Type

this
Back to top