class Synapse::Command::CommandCallback
Callback that is notified of the outcome of the dispatch of a command @abstract
Public Instance Methods
on_failure(exception)
click to toggle source
Called when a dispatch fails due to an exception
@abstract @param [Exception] exception The cause of the failure @return [undefined]
# File lib/synapse/command/command_callback.rb, line 20 def on_failure(exception) raise NotImplementedError end
on_success(result)
click to toggle source
Called when a dispatch is successful
@abstract @param [Object] result The result from the command handler @return [undefined]
# File lib/synapse/command/command_callback.rb, line 11 def on_success(result) raise NotImplementedError end