Class: Pubnub::State

Inherits:
SingleEvent show all
Includes:
Celluloid, Validator::State
Defined in:
lib/pubnub/events/state.rb

Overview

Holds state functionality

Instance Attribute Summary

Attributes inherited from Event

#callback, #channel, #fresh_clone, #given_options, #group, #idle_timeout, #open_timeout, #origin, #presence_callback, #read_timeout, #ssl, #state, #wildcard_channel

Instance Method Summary collapse

Methods included from Validator::State

#validate!

Methods included from Validator::CommonValidator

#validate_origin, #validate_publish_key, #validate_subscribe_key

Methods inherited from Event

#finalized?, #fire, #send_request, #sync?, #uri

Constructor Details

#initialize(options, app) ⇒ State

Returns a new instance of State.



8
9
10
11
12
13
# File 'lib/pubnub/events/state.rb', line 8

def initialize(options, app)
  @event = :state
  @uuid_looking_for = options[:uuid] || options['uuid']
  super
  @uuid = app.uuid
end