Options
All
  • Public
  • Public/Protected
  • All
Menu

Class EyeGazeDataStream

Hierarchy

  • EyeGazeDataStream

Index

Properties

Protected _eyeGazeDataStreams

_eyeGazeDataStreams: EyeGazeDataStreams = new EyeGazeDataStreams()

Protected _eyeGazeEventTarget

_eyeGazeEventTarget: EventTarget = new EventTarget()

Protected _webSocket

_webSocket: WebSocket

Static Readonly BINARY_MESSAGE_PARSING_ERROR

BINARY_MESSAGE_PARSING_ERROR: "binarymessageparsingerror" = "binarymessageparsingerror"

Static Readonly CONNECTION_ERROR

CONNECTION_ERROR: "connection error with server" = "connection error with server"

Static Readonly CONNECTION_STATUS

CONNECTION_STATUS: "connectionstatus" = "connectionstatus"

Static Readonly DISCONNECTED_TO_SERVER

DISCONNECTED_TO_SERVER: "disconnected to server" = "disconnected to server"

Static Readonly EYE_GAZE_DATA

EYE_GAZE_DATA: "eyegazedata" = "eyegazedata"

Static Readonly NEW_SERVER_MESSAGE

NEW_SERVER_MESSAGE: "newservermessage" = "newservermessage"

Static Readonly SUCCESSFULLY_CONNECTED_TO_SERVER

SUCCESSFULLY_CONNECTED_TO_SERVER: "successfully connected to server" = "successfully connected to server"

Accessors

connectionState

  • get connectionState(): number

eyeGazeDataStreams

Methods

addEventListener

  • addEventListener(type: string, listener: EventListenerOrEventListenerObject | null, options?: boolean | AddEventListenerOptions): void
  • Parameters

    • type: string
    • listener: EventListenerOrEventListenerObject | null
    • Optional options: boolean | AddEventListenerOptions

    Returns void

connect

  • connect(serverAddress: string): void

dispatchEvent

  • dispatchEvent(event: Event): boolean

Protected generateStreamConfigByte

  • generateStreamConfigByte(): Uint8Array

Protected onClose

  • onClose(event: Event): void

Protected onError

  • onError(event: Event): void

Protected onMessage

  • onMessage(event: MessageEvent): Promise<void>

Protected onOpen

  • onOpen(event: Event): void

Protected parseEyeTrackingData

Protected performHandshake

  • performHandshake(): void

removeEventListener

  • removeEventListener(type: string, callback: EventListenerOrEventListenerObject | null, options?: EventListenerOptions | boolean): void
  • Parameters

    • type: string
    • callback: EventListenerOrEventListenerObject | null
    • Optional options: EventListenerOptions | boolean

    Returns void