Class: Pokemon::Ability
- Inherits:
-
Object
- Object
- Pokemon::Ability
- Defined in:
- lib/pokemon_tcg_sdk/ability.rb
Instance Attribute Summary collapse
-
#name ⇒ Object
Returns the value of attribute name.
-
#text ⇒ Object
Returns the value of attribute text.
-
#type ⇒ Object
Returns the value of attribute type.
Class Method Summary collapse
Instance Attribute Details
#name ⇒ Object
Returns the value of attribute name.
3 4 5 |
# File 'lib/pokemon_tcg_sdk/ability.rb', line 3 def name @name end |
#text ⇒ Object
Returns the value of attribute text.
3 4 5 |
# File 'lib/pokemon_tcg_sdk/ability.rb', line 3 def text @text end |
#type ⇒ Object
Returns the value of attribute type.
3 4 5 |
# File 'lib/pokemon_tcg_sdk/ability.rb', line 3 def type @type end |
Class Method Details
.from_json(json) ⇒ Object
5 6 7 8 9 10 11 12 |
# File 'lib/pokemon_tcg_sdk/ability.rb', line 5 def self.from_json(json) ability = Ability.new ability.name = json['name'] ability.text = json['text'] ability.type = json['type'] ability end |