Exception: MotherBrain::DataBagItemNotFound
Constant Summary
Constants inherited from MBError
Instance Attribute Summary collapse
-
#data_bag_name ⇒ Object
readonly
Returns the value of attribute data_bag_name.
-
#item_name ⇒ Object
readonly
Returns the value of attribute item_name.
Instance Method Summary collapse
-
#initialize(data_bag_name, item_name) ⇒ DataBagItemNotFound
constructor
A new instance of DataBagItemNotFound.
- #message ⇒ Object
Methods inherited from MBError
#error_code, error_code, exit_code, #exit_code, #to_hash, #to_json, #to_s
Constructor Details
#initialize(data_bag_name, item_name) ⇒ DataBagItemNotFound
Returns a new instance of DataBagItemNotFound.
638 639 640 641 |
# File 'lib/mb/errors.rb', line 638 def initialize(data_bag_name, item_name) @data_bag_name = data_bag_name @item_name = item_name end |
Instance Attribute Details
#data_bag_name ⇒ Object (readonly)
Returns the value of attribute data_bag_name.
635 636 637 |
# File 'lib/mb/errors.rb', line 635 def data_bag_name @data_bag_name end |
#item_name ⇒ Object (readonly)
Returns the value of attribute item_name.
636 637 638 |
# File 'lib/mb/errors.rb', line 636 def item_name @item_name end |
Instance Method Details
#message ⇒ Object
643 644 645 |
# File 'lib/mb/errors.rb', line 643 def "An item named '#{item_name}' was not found in the '#{data_bag_name}' data bag." end |