Skip to content

CoffeeScript documentation

simonoff edited this page Feb 25, 2013 · 5 revisions

reset()

Reset all

faye(callback)

Connect to faye

connectToFaye()

Initialize Faye client

sign(options)

Sign to channel

Parameters

  • options (Object) — for signing
  1. server (String) - server url
  2. channel (String) - channel name
  3. signature (String) - secure hash
  4. timestamp (Number) - connection timestamp
  5. callback (Function) - callback function on incoming message
  6. connect (function) - callback function what called after subscribing on channel
  7. error (Function) - callback function what called if subscribing has an error

handleResponse(message)

Handle response from Faye

Parameters

  • message (Object) — message object from Faye

subscribe(channel, callback, options)

Subscribe to channel with callback

Parameters

  • channel (String) — Channel name
  • callback (Function) — Callback function
  • options (Object) — subscription callbacks options

unsubscribe(channel, fullUnsubscribe)

Unsubscribe from channel

Parameters

  • channel (String) — name of channel
  • fullUnsubscribe (Boolean) - Full unsubscribe

unsubscribeAll()

Unsubscribe from all channels

disableTransport(transport)

Disable Faye transport

Parameters

  • transport (String) - name of the transport