Class: SpringStandalone::Client::Stop

Inherits:
Command
  • Object
show all
Defined in:
lib/spring_standalone/client/stop.rb

Instance Attribute Summary

Attributes inherited from Command

#args, #env

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Command

call, #initialize

Constructor Details

This class inherits a constructor from SpringStandalone::Client::Command

Class Method Details

.descriptionObject



6
7
8
# File 'lib/spring_standalone/client/stop.rb', line 6

def self.description
  "Stop all SpringStandalone processes for this project."
end

Instance Method Details

#callObject



10
11
12
13
14
15
16
17
18
19
# File 'lib/spring_standalone/client/stop.rb', line 10

def call
  case env.stop
  when :stopped
    puts "SpringStandalone stopped."
  when :killed
    $stderr.puts "SpringStandalone did not stop; killing forcibly."
  when :not_running
    puts "SpringStandalone is not running"
  end
end