class Faye::WebSocket::API::Event
Constants
- AT_TARGET
- BUBBLING_PHASE
- CAPTURING_PHASE
Attributes
bubbles[R]
cancelable[R]
current_target[RW]
event_phase[RW]
target[RW]
type[R]
Public Class Methods
create(type, options = {})
click to toggle source
# File lib/faye/websocket/api/event.rb, line 51 def Event.create(type, options = {}) TYPES[type].new(type, options) end
new(event_type, options)
click to toggle source
# File lib/faye/websocket/api/event.rb, line 11 def initialize(event_type, options) @type = event_type options.each { |key, value| instance_variable_set("@#{ key }", value) } end
Public Instance Methods
init_event(event_type, can_bubble, cancelable)
click to toggle source
# File lib/faye/websocket/api/event.rb, line 16 def init_event(event_type, can_bubble, cancelable) @type = event_type @bubbles = can_bubble @cancelable = cancelable end
prevent_default()
click to toggle source
# File lib/faye/websocket/api/event.rb, line 25 def prevent_default end
stop_propagation()
click to toggle source
# File lib/faye/websocket/api/event.rb, line 22 def stop_propagation end