Exception: MotherBrain::JobNotFound

Inherits:
MBError
  • Object
show all
Defined in:
lib/mb/errors.rb

Constant Summary

Constants inherited from MBError

MBError::DEFAULT_EXIT_CODE

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from MBError

#error_code, error_code, exit_code, #exit_code, #to_hash, #to_json, #to_s

Constructor Details

#initialize(id) ⇒ JobNotFound

Returns a new instance of JobNotFound.



246
247
248
# File 'lib/mb/errors.rb', line 246

def initialize(id)
  @job_id = id
end

Instance Attribute Details

#job_idObject (readonly)

Returns the value of attribute job_id.



244
245
246
# File 'lib/mb/errors.rb', line 244

def job_id
  @job_id
end

Instance Method Details

#messageObject



250
251
252
# File 'lib/mb/errors.rb', line 250

def message
  "No job with ID: '#{job_id}' found"
end