Class: PokeApi::ItemCategory
- Inherits:
-
NamedApiResource
- Object
- NamedApiResource
- PokeApi::ItemCategory
- Defined in:
- lib/poke_api/item_category.rb
Overview
ItemCategory object handling all data fetched from /item-category
Instance Attribute Summary collapse
-
#items ⇒ Object
readonly
Returns the value of attribute items.
-
#names ⇒ Object
readonly
Returns the value of attribute names.
-
#pocket ⇒ Object
readonly
Returns the value of attribute pocket.
Attributes inherited from NamedApiResource
Instance Method Summary collapse
-
#initialize(data) ⇒ ItemCategory
constructor
A new instance of ItemCategory.
Methods inherited from NamedApiResource
Methods included from AssignmentHelpers
assign_list, custom_endpoint_object, endpoint_assignment, get_named_api_resource_from_url, try_to_assign
Constructor Details
#initialize(data) ⇒ ItemCategory
Returns a new instance of ItemCategory.
8 9 10 |
# File 'lib/poke_api/item_category.rb', line 8 def initialize(data) assign_data(data) end |
Instance Attribute Details
#items ⇒ Object (readonly)
Returns the value of attribute items.
4 5 6 |
# File 'lib/poke_api/item_category.rb', line 4 def items @items end |
#names ⇒ Object (readonly)
Returns the value of attribute names.
4 5 6 |
# File 'lib/poke_api/item_category.rb', line 4 def names @names end |
#pocket ⇒ Object (readonly)
Returns the value of attribute pocket.
4 5 6 |
# File 'lib/poke_api/item_category.rb', line 4 def pocket @pocket end |