Class: Redress::Command
- Inherits:
-
Object
- Object
- Redress::Command
- Includes:
- Wisper::Publisher
- Defined in:
- lib/redress/command.rb
Class Method Summary collapse
Class Method Details
.call(*args, &block) ⇒ Object
9 10 11 12 |
# File 'lib/redress/command.rb', line 9 def self.call(*args, &block) run(*args, &block) nil end |
.run(*args) {|command| ... } ⇒ Object
14 15 16 17 18 19 |
# File 'lib/redress/command.rb', line 14 def self.run(*args) command = new(*args) yield command if block_given? command.call command end |