Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

Index

Properties

clients: Set<WebSocket>
path: string

Methods

  • Parameters

    • event: "connection"
    • cb: (client: WebSocket, request: IncomingMessage) => void
        • (client: WebSocket, request: IncomingMessage): void
        • Parameters

          Returns void

    Returns WebSocket.WebSocketServer

  • Parameters

    • event: "error"
    • cb: (err: Error) => void
        • (err: Error): void
        • Parameters

          • err: Error

          Returns void

    Returns WebSocket.WebSocketServer

  • Parameters

    • event: "headers"
    • cb: (headers: string[], request: IncomingMessage) => void
        • (headers: string[], request: IncomingMessage): void
        • Parameters

          • headers: string[]
          • request: IncomingMessage

          Returns void

    Returns WebSocket.WebSocketServer

  • Parameters

    • event: "close" | "listening"
    • cb: () => void
        • (): void
        • Returns void

    Returns WebSocket.WebSocketServer

  • Parameters

    • event: string | symbol
    • listener: (...args: any[]) => void
        • (...args: any[]): void
        • Parameters

          • Rest ...args: any[]

          Returns void

    Returns WebSocket.WebSocketServer

  • close(cb?: (err?: Error) => void): void
  • Parameters

    • Optional cb: (err?: Error) => void
        • (err?: Error): void
        • Parameters

          • Optional err: Error

          Returns void

    Returns void

  • handleUpgrade(request: IncomingMessage, socket: Duplex, upgradeHead: Buffer, callback: (client: WebSocket, request: IncomingMessage) => void): void
  • Parameters

    • request: IncomingMessage
    • socket: Duplex
    • upgradeHead: Buffer
    • callback: (client: WebSocket, request: IncomingMessage) => void
        • (client: WebSocket, request: IncomingMessage): void
        • Parameters

          Returns void

    Returns void

  • Parameters

    Returns WebSocket.WebSocketServer

  • Parameters

    • event: "error"
    • cb: (err: Error) => void
        • (err: Error): void
        • Parameters

          • err: Error

          Returns void

    Returns WebSocket.WebSocketServer

  • Parameters

    • event: "headers"
    • cb: (headers: string[], request: IncomingMessage) => void
        • (headers: string[], request: IncomingMessage): void
        • Parameters

          • headers: string[]
          • request: IncomingMessage

          Returns void

    Returns WebSocket.WebSocketServer

  • Parameters

    • event: "close" | "listening"
    • cb: () => void
        • (): void
        • Returns void

    Returns WebSocket.WebSocketServer

  • Parameters

    • event: string | symbol
    • listener: (...args: any[]) => void
        • (...args: any[]): void
        • Parameters

          • Rest ...args: any[]

          Returns void

    Returns WebSocket.WebSocketServer

  • shouldHandle(request: IncomingMessage): boolean | Promise<boolean>
  • Parameters

    • request: IncomingMessage

    Returns boolean | Promise<boolean>