class Apotomo::EventHandler

EventHandlers are “callbacks”, not knowing why they exist, but what to do.

Public Instance Methods

==(other) click to toggle source
# File lib/apotomo/event_handler.rb, line 10
def ==(other)
  self.to_s == other.to_s
end
call(event) click to toggle source

Invoked by Onfire.

# File lib/apotomo/event_handler.rb, line 15
def call(event)
  event.source.root.page_updates << process_event(event)
end
process_event(event) click to toggle source
# File lib/apotomo/event_handler.rb, line 5
def process_event(event)
  # do something, and return content.
  nil
end