Class: IRC::Callback
- Inherits:
-
Object
- Object
- IRC::Callback
- Defined in:
- lib/on_irc/callback.rb
Defined Under Namespace
Classes: CallbackDSL
Instance Method Summary collapse
- #call(irc, event) ⇒ Object
-
#initialize(block) ⇒ Callback
constructor
A new instance of Callback.
Constructor Details
#initialize(block) ⇒ Callback
Returns a new instance of Callback.
3 4 5 |
# File 'lib/on_irc/callback.rb', line 3 def initialize(block) @block = block end |
Instance Method Details
#call(irc, event) ⇒ Object
7 8 9 |
# File 'lib/on_irc/callback.rb', line 7 def call(irc, event) CallbackDSL.run(irc, event, @block) end |