Exception: System::Exception::CriticalException

Inherits:
Exception
  • Object
show all
Defined in:
lib/system/exception.rb

Instance Method Summary collapse

Constructor Details

#initialize(message, command, exit) ⇒ CriticalException

Returns a new instance of CriticalException.



4
5
6
7
8
# File 'lib/system/exception.rb', line 4

def initialize(message, command, exit)
  @message = message
  @command = command
  @exit = exit
end

Instance Method Details

#to_sObject



10
11
12
13
14
15
16
17
# File 'lib/system/exception.rb', line 10

def to_s
  <<EOF
#{@message}

Command (#{@command}) exiting with code #{@exit}

EOF
end