Class StandaloneWebsocketRoute

Represents a standalone WebSocket route that handles WebSocket requests independently. This way, routes without parent routes can be registered and are still allowed to contain . path separators.

Hierarchy

Constructors

  • Creates an instance of StandaloneWebsocketRoute.

    Parameters

    • method: string

      The method name for the route.

    • objConfig: {
          propertyKey: string;
          target: any;
      }

      The configuration object for the object method.

      • propertyKey: string

        The property key of the target object.

      • target: any

        The target object.

    • Optional modifiesAuthentication: boolean

      Indicates whether the route modifies authentication.

    Returns StandaloneWebsocketRoute

Properties

authenticator: WebsocketAuthenticator = null
children: WebsocketRoute[] = []
isOutbound: boolean = false
method: string
objConfig: {
    propertyKey: string;
    target: any;
}

The configuration object for the object method.

Type declaration

  • propertyKey: string
  • target: any

Accessors

  • get Func(): ((...data) => any)
  • Returns the decorated function with added authentication checks.

    Returns ((...data) => any)

    • The decorated function.
      • (...data): any
      • Returns the decorated function with added authentication checks.

        Parameters

        • Rest ...data: any[]

        Returns any

        • The decorated function.
  • get hasAuthenticator(): boolean
  • Checks if the decorated function has an authenticator.

    Returns boolean

    • Indicates whether the decorated function has an authenticator.

Methods

  • Protected

    Calls the object method associated with the route and handles the response.

    Parameters

    Returns Promise<any>

    • The response of the object method.

    Throws

    • If the object method is not defined for the route.
  • Registers the outbound methods whose data is potentially modified during the execution of this route.

    Parameters

    • outboundRoutes: string[]

      The outbound routes that are potentially modified.

    • Optional filter: MessageFilter

      The message filter.

    Returns void

Generated using TypeDoc