Class: BackboneSync::Rails::Faye::Event

Inherits:
Object
  • Object
show all
Defined in:
lib/backbone_sync-rails/faye/event.rb

Instance Method Summary collapse

Constructor Details

#initialize(model, event) ⇒ Event

Returns a new instance of Event.



7
8
9
10
# File 'lib/backbone_sync-rails/faye/event.rb', line 7

def initialize(model, event)
  @model = model
  @event = event
end

Instance Method Details

#broadcastObject



12
13
14
# File 'lib/backbone_sync-rails/faye/event.rb', line 12

def broadcast
  Net::HTTP.post_form(uri, :message => message)
end