Class: Hearthstone::Models::Card
- Inherits:
-
Object
- Object
- Hearthstone::Models::Card
- Defined in:
- lib/hearthstone/models/card.rb
Instance Attribute Summary collapse
-
#artist ⇒ Object
Returns the value of attribute artist.
-
#attack ⇒ Object
Returns the value of attribute attack.
-
#collectible ⇒ Object
Returns the value of attribute collectible.
-
#cost ⇒ Object
Returns the value of attribute cost.
-
#elite ⇒ Object
Returns the value of attribute elite.
-
#faction ⇒ Object
Returns the value of attribute faction.
-
#flavor ⇒ Object
Returns the value of attribute flavor.
-
#health ⇒ Object
Returns the value of attribute health.
-
#id ⇒ Object
Returns the value of attribute id.
-
#mechanics ⇒ Object
Returns the value of attribute mechanics.
-
#name ⇒ Object
Returns the value of attribute name.
-
#rarity ⇒ Object
Returns the value of attribute rarity.
-
#text ⇒ Object
Returns the value of attribute text.
-
#type ⇒ Object
Returns the value of attribute type.
Instance Method Summary collapse
Instance Attribute Details
#artist ⇒ Object
Returns the value of attribute artist.
5 6 7 |
# File 'lib/hearthstone/models/card.rb', line 5 def artist @artist end |
#attack ⇒ Object
Returns the value of attribute attack.
5 6 7 |
# File 'lib/hearthstone/models/card.rb', line 5 def attack @attack end |
#collectible ⇒ Object
Returns the value of attribute collectible.
5 6 7 |
# File 'lib/hearthstone/models/card.rb', line 5 def collectible @collectible end |
#cost ⇒ Object
Returns the value of attribute cost.
4 5 6 |
# File 'lib/hearthstone/models/card.rb', line 4 def cost @cost end |
#elite ⇒ Object
Returns the value of attribute elite.
5 6 7 |
# File 'lib/hearthstone/models/card.rb', line 5 def elite @elite end |
#faction ⇒ Object
Returns the value of attribute faction.
4 5 6 |
# File 'lib/hearthstone/models/card.rb', line 4 def faction @faction end |
#flavor ⇒ Object
Returns the value of attribute flavor.
4 5 6 |
# File 'lib/hearthstone/models/card.rb', line 4 def flavor @flavor end |
#health ⇒ Object
Returns the value of attribute health.
5 6 7 |
# File 'lib/hearthstone/models/card.rb', line 5 def health @health end |
#id ⇒ Object
Returns the value of attribute id.
5 6 7 |
# File 'lib/hearthstone/models/card.rb', line 5 def id @id end |
#mechanics ⇒ Object
Returns the value of attribute mechanics.
4 5 6 |
# File 'lib/hearthstone/models/card.rb', line 4 def mechanics @mechanics end |
#name ⇒ Object
Returns the value of attribute name.
4 5 6 |
# File 'lib/hearthstone/models/card.rb', line 4 def name @name end |
#rarity ⇒ Object
Returns the value of attribute rarity.
4 5 6 |
# File 'lib/hearthstone/models/card.rb', line 4 def rarity @rarity end |
#text ⇒ Object
Returns the value of attribute text.
4 5 6 |
# File 'lib/hearthstone/models/card.rb', line 4 def text @text end |
#type ⇒ Object
Returns the value of attribute type.
4 5 6 |
# File 'lib/hearthstone/models/card.rb', line 4 def type @type end |
Instance Method Details
#eql?(other) ⇒ Boolean
7 8 9 |
# File 'lib/hearthstone/models/card.rb', line 7 def eql?(other) other.equal?(id) || id == other.id end |
#hash ⇒ Object
11 12 13 |
# File 'lib/hearthstone/models/card.rb', line 11 def hash id.hash end |
#to_s ⇒ Object
15 16 17 |
# File 'lib/hearthstone/models/card.rb', line 15 def to_s "<Card \"#{name}\">" end |