module Seahorse::Client::EventEmitter

Public Class Methods

new(*args) click to toggle source
Calls superclass method
# File lib/seahorse/client/events.rb, line 5
def initialize(*args)
  @listeners = {}
  super
end

Public Instance Methods

emit(event_name, *args, &block) click to toggle source
# File lib/seahorse/client/events.rb, line 10
def emit(event_name, *args, &block)
  @listeners[event_name] ||= []
  @listeners[event_name] << Proc.new
end
signal(event, *args) click to toggle source
# File lib/seahorse/client/events.rb, line 15
def signal(event, *args)
  @listeners
end