Class: D3api::Hero
- Includes:
- Request
- Defined in:
- lib/d3api/hero.rb
Instance Attribute Summary collapse
-
#active_skills ⇒ Object
Returns the value of attribute active_skills.
-
#followers ⇒ Object
Returns the value of attribute followers.
-
#gender ⇒ Object
Returns the value of attribute gender.
-
#hardcore ⇒ Object
Returns the value of attribute hardcore.
-
#hero_class ⇒ Object
Returns the value of attribute hero_class.
-
#id ⇒ Object
Returns the value of attribute id.
-
#items ⇒ Object
Returns the value of attribute items.
-
#last_updated ⇒ Object
Returns the value of attribute last_updated.
-
#level ⇒ Object
Returns the value of attribute level.
-
#name ⇒ Object
Returns the value of attribute name.
-
#passive_skills ⇒ Object
Returns the value of attribute passive_skills.
-
#stats ⇒ Object
Returns the value of attribute stats.
Instance Method Summary collapse
-
#initialize(region, battletag_name, battletag_id, hero_id) ⇒ Hero
constructor
A new instance of Hero.
Methods included from Request
Methods included from Connection
Constructor Details
#initialize(region, battletag_name, battletag_id, hero_id) ⇒ Hero
Returns a new instance of Hero.
9 10 11 12 13 14 15 |
# File 'lib/d3api/hero.rb', line 9 def initialize(region, battletag_name, battletag_id, hero_id) json_response = find(region, battletag_name, battletag_id, hero_id) values = super json_response set_method(values) end |
Instance Attribute Details
#active_skills ⇒ Object
Returns the value of attribute active_skills.
4 5 6 |
# File 'lib/d3api/hero.rb', line 4 def active_skills @active_skills end |
#followers ⇒ Object
Returns the value of attribute followers.
4 5 6 |
# File 'lib/d3api/hero.rb', line 4 def followers @followers end |
#gender ⇒ Object
Returns the value of attribute gender.
4 5 6 |
# File 'lib/d3api/hero.rb', line 4 def gender @gender end |
#hardcore ⇒ Object
Returns the value of attribute hardcore.
4 5 6 |
# File 'lib/d3api/hero.rb', line 4 def hardcore @hardcore end |
#hero_class ⇒ Object
Returns the value of attribute hero_class.
4 5 6 |
# File 'lib/d3api/hero.rb', line 4 def hero_class @hero_class end |
#id ⇒ Object
Returns the value of attribute id.
4 5 6 |
# File 'lib/d3api/hero.rb', line 4 def id @id end |
#items ⇒ Object
Returns the value of attribute items.
4 5 6 |
# File 'lib/d3api/hero.rb', line 4 def items @items end |
#last_updated ⇒ Object
Returns the value of attribute last_updated.
4 5 6 |
# File 'lib/d3api/hero.rb', line 4 def last_updated @last_updated end |
#level ⇒ Object
Returns the value of attribute level.
4 5 6 |
# File 'lib/d3api/hero.rb', line 4 def level @level end |
#name ⇒ Object
Returns the value of attribute name.
4 5 6 |
# File 'lib/d3api/hero.rb', line 4 def name @name end |
#passive_skills ⇒ Object
Returns the value of attribute passive_skills.
4 5 6 |
# File 'lib/d3api/hero.rb', line 4 def passive_skills @passive_skills end |
#stats ⇒ Object
Returns the value of attribute stats.
4 5 6 |
# File 'lib/d3api/hero.rb', line 4 def stats @stats end |