pixie v0.3.9 Pixie.Message.Subscribe

Convert an incoming subscription request into a struct.

Request
MUST include:  * channel
               * clientId
               * subscription
MAY include:   * ext
               * id

This struct contains the following keys:

  • :channel always "/meta/subscribe".
  • :subscription the channel the user wishes to subscribe to.
  • :client_id the client ID generated by the server during handshake.
  • :ext an arbitrary map of data the client sent for use in extensions (usually authentication information, etc). Optional.
  • :id a message ID generated by the client. Optional.

Summary

Functions

Convert the incoming message into a Pixie.Message.Subscribe by copying only those fields we care about

Functions

init(message)

Convert the incoming message into a Pixie.Message.Subscribe by copying only those fields we care about.