Class: Moneypenny::Connections::Echo

Inherits:
Object
  • Object
show all
Defined in:
lib/moneypenny/connections/echo.rb

Instance Method Summary collapse

Instance Method Details

#listen(&block) ⇒ Object



8
9
10
# File 'lib/moneypenny/connections/echo.rb', line 8

def listen(&block)
  @listener = block
end

#say(message) ⇒ Object



4
5
6
# File 'lib/moneypenny/connections/echo.rb', line 4

def say(message)
  @listener.call message
end