Class: Degica::InventoryCollection
- Inherits:
-
ObjectCollection
- Object
- Array
- Collection
- ObjectCollection
- Degica::InventoryCollection
- Defined in:
- lib/degica/collections/inventory_collection.rb
Instance Method Summary collapse
Methods inherited from ObjectCollection
Methods inherited from Collection
Methods included from Actionable
Constructor Details
This class inherits a constructor from Degica::Collection
Instance Method Details
#describe ⇒ Object
7 8 9 10 11 12 13 |
# File 'lib/degica/collections/inventory_collection.rb', line 7 def describe if empty? "You have no items in your inventory." else "[" + map(&:name).join(', ') + "]" end end |
#prompt ⇒ Object
3 4 5 |
# File 'lib/degica/collections/inventory_collection.rb', line 3 def prompt "inventory" end |