Module: Euston::CommandHandler::ClassMethods
- Defined in:
- lib/euston/command_handler.rb
Instance Method Summary collapse
Instance Method Details
#version(number, &consumer) ⇒ Object
7 8 9 10 11 12 13 14 15 |
# File 'lib/euston/command_handler.rb', line 7 def version number, &consumer define_method command_handler_method_name(number) do |*args| if block_given? instance_exec *args, &consumer else publish args.shift, args.shift end end end |