Exception: ProcessFailed
- Inherits:
-
StandardError
- Object
- StandardError
- ProcessFailed
- Defined in:
- lib/scout/exceptions.rb
Direct Known Subclasses
Instance Attribute Summary collapse
-
#msg ⇒ Object
Returns the value of attribute msg.
-
#pid ⇒ Object
Returns the value of attribute pid.
Instance Method Summary collapse
-
#initialize(pid = Process.pid, msg = nil) ⇒ ProcessFailed
constructor
A new instance of ProcessFailed.
Constructor Details
#initialize(pid = Process.pid, msg = nil) ⇒ ProcessFailed
Returns a new instance of ProcessFailed.
24 25 26 27 28 29 30 31 32 33 34 35 36 37 |
# File 'lib/scout/exceptions.rb', line 24 def initialize(pid = Process.pid, msg = nil) @pid = pid @msg = msg if @pid if @msg = "Process #{@pid} failed - #{@msg}" else = "Process #{@pid} failed" end else = "Failed to run #{@msg}" end super() end |
Instance Attribute Details
#msg ⇒ Object
Returns the value of attribute msg.
23 24 25 |
# File 'lib/scout/exceptions.rb', line 23 def msg @msg end |
#pid ⇒ Object
Returns the value of attribute pid.
23 24 25 |
# File 'lib/scout/exceptions.rb', line 23 def pid @pid end |