Interface HubConnection

Hierarchy

Index

Call signatures

Properties

Methods

Call signatures

(url: string, queryString?: any, logging?: boolean): SignalR

Parameters

  • url: string
  • queryString?: any optional
  • logging?: boolean optional

Returns

SignalR

Properties

public connectionState: any

public events: SignalREvents

public hub: HubConnection

public id: string

public logging: boolean

public messageId: string

public proxies: any

public qs: any

public transports: any

public url: string

Methods

public changeState(connection: SignalR, expectedState: number, newState: number): boolean

Parameters

  • connection: SignalR
  • expectedState: number
  • newState: number

Returns

boolean

public connectionSlow(handler: () => void): SignalR

Parameters

  • handler: () => void

Returns

SignalR

public createHubProxy(hubName: string): HubProxy

Parameters

  • hubName: string

Returns

HubProxy

public disconnected(handler: () => void): SignalR

Parameters

  • handler: () => void

Returns

SignalR

public error(handler: (error: string) => void): SignalR

Parameters

  • handler: (error: string) => void

Returns

SignalR

public hubConnection(url?: string): SignalR

Parameters

  • url?: string optional

Returns

SignalR

public isCrossDomain(url: string): boolean

Parameters

  • url: string

Returns

boolean

public isDisconnecting(connection: SignalR): boolean

Parameters

Returns

boolean

public log(msg: string, logging: boolean)

Parameters

  • msg: string
  • logging: boolean

public received(callback: (data: { Id: any; Method: any; Hub: any; State: any; Args: any; }) => void): HubConnection

Parameters

  • callback: (data: { Id: any; Method: any; Hub: any; State: any; Args: any; }) => void

Returns

HubConnection

public reconnected(handler: () => void): SignalR

Parameters

  • handler: () => void

Returns

SignalR

public reconnecting(handler: () => void): SignalR

Parameters

  • handler: () => void

Returns

SignalR

public send(data: string)

Parameters

  • data: string

public sending(handler: () => void): SignalR

Parameters

  • handler: () => void

Returns

SignalR

public start(): JQueryPromise

Returns

JQueryPromise

public start(callback: () => void): JQueryPromise

Parameters

  • callback: () => void

Returns

JQueryPromise

public start(settings: ConnectionSettings): JQueryPromise

Parameters

Returns

JQueryPromise

public start(settings: ConnectionSettings, callback: () => void): JQueryPromise

Parameters

Returns

JQueryPromise

public starting(handler: () => void): SignalR

Parameters

  • handler: () => void

Returns

SignalR

public stateChanged(handler: (change: SignalRStateChange) => void): SignalR

Parameters

  • handler: (change: SignalRStateChange) => void

Returns

SignalR

public stop(async?: boolean, notifyServer?: boolean)

Parameters

  • async?: boolean optional
  • notifyServer?: boolean optional