Class: Semaph::Commands::StopWorkflowCommand

Inherits:
Object
  • Object
show all
Defined in:
lib/semaph/commands/stop_workflow_command.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(workflow) ⇒ StopWorkflowCommand

Returns a new instance of StopWorkflowCommand.



6
7
8
9
# File 'lib/semaph/commands/stop_workflow_command.rb', line 6

def initialize(workflow)
  @workflow = workflow
  @help = "stop workflow"
end

Instance Attribute Details

#helpObject (readonly)

Returns the value of attribute help.



4
5
6
# File 'lib/semaph/commands/stop_workflow_command.rb', line 4

def help
  @help
end

Instance Method Details

#execute(_whatever) ⇒ Object



11
12
13
# File 'lib/semaph/commands/stop_workflow_command.rb', line 11

def execute(_whatever)
  @workflow.stop
end