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.
655 656 657 658 |
# File 'lib/mb/errors.rb', line 655 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.
652 653 654 |
# File 'lib/mb/errors.rb', line 652 def data_bag_name @data_bag_name end |
#item_name ⇒ Object (readonly)
Returns the value of attribute item_name.
653 654 655 |
# File 'lib/mb/errors.rb', line 653 def item_name @item_name end |
Instance Method Details
#message ⇒ Object
660 661 662 |
# File 'lib/mb/errors.rb', line 660 def "An item named '#{item_name}' was not found in the '#{data_bag_name}' data bag." end |