Class: Sightstone::MatchHistory
- Inherits:
-
Object
- Object
- Sightstone::MatchHistory
- Defined in:
- lib/sightstone/match_history.rb
Instance Attribute Summary collapse
-
#games ⇒ Array<HistoryGame>
unsorted list of recently played games.
-
#summonerId ⇒ Object
Returns the value of attribute summonerId.
Instance Method Summary collapse
-
#initialize(data) ⇒ MatchHistory
constructor
A new instance of MatchHistory.
Constructor Details
#initialize(data) ⇒ MatchHistory
Returns a new instance of MatchHistory.
8 9 10 11 12 13 14 |
# File 'lib/sightstone/match_history.rb', line 8 def initialize(data) @summonerId = data['summonerId'] @games = [] data['games'].each do |game| games << HistoryGame.new(game) end end |
Instance Attribute Details
#games ⇒ Array<HistoryGame>
unsorted list of recently played games
5 6 7 |
# File 'lib/sightstone/match_history.rb', line 5 def games @games end |
#summonerId ⇒ Object
Returns the value of attribute summonerId.
6 7 8 |
# File 'lib/sightstone/match_history.rb', line 6 def summonerId @summonerId end |