Class: RiotKit::Models::Riot::MatchDetail
- Inherits:
-
Object
- Object
- RiotKit::Models::Riot::MatchDetail
- Defined in:
- lib/riot_kit/models/riot/match_detail.rb
Instance Attribute Summary collapse
-
#game_creation ⇒ Object
readonly
Returns the value of attribute game_creation.
-
#game_duration_seconds ⇒ Object
readonly
Returns the value of attribute game_duration_seconds.
-
#match_id ⇒ Object
readonly
Returns the value of attribute match_id.
-
#participants ⇒ Object
readonly
Returns the value of attribute participants.
-
#queue_id ⇒ Object
readonly
Returns the value of attribute queue_id.
-
#queue_label ⇒ Object
readonly
Returns the value of attribute queue_label.
-
#teams ⇒ Object
readonly
Returns the value of attribute teams.
Instance Method Summary collapse
-
#initialize(match_id:, game_duration_seconds:, queue_id:, queue_label:, game_creation:, teams:, participants:) ⇒ MatchDetail
constructor
A new instance of MatchDetail.
- #to_h ⇒ Object
Constructor Details
#initialize(match_id:, game_duration_seconds:, queue_id:, queue_label:, game_creation:, teams:, participants:) ⇒ MatchDetail
Returns a new instance of MatchDetail.
10 11 12 13 14 15 16 17 18 19 |
# File 'lib/riot_kit/models/riot/match_detail.rb', line 10 def initialize(match_id:, game_duration_seconds:, queue_id:, queue_label:, game_creation:, teams:, participants:) @match_id = match_id @game_duration_seconds = game_duration_seconds @queue_id = queue_id @queue_label = queue_label @game_creation = game_creation @teams = teams @participants = participants end |
Instance Attribute Details
#game_creation ⇒ Object (readonly)
Returns the value of attribute game_creation.
7 8 9 |
# File 'lib/riot_kit/models/riot/match_detail.rb', line 7 def game_creation @game_creation end |
#game_duration_seconds ⇒ Object (readonly)
Returns the value of attribute game_duration_seconds.
7 8 9 |
# File 'lib/riot_kit/models/riot/match_detail.rb', line 7 def game_duration_seconds @game_duration_seconds end |
#match_id ⇒ Object (readonly)
Returns the value of attribute match_id.
7 8 9 |
# File 'lib/riot_kit/models/riot/match_detail.rb', line 7 def match_id @match_id end |
#participants ⇒ Object (readonly)
Returns the value of attribute participants.
7 8 9 |
# File 'lib/riot_kit/models/riot/match_detail.rb', line 7 def participants @participants end |
#queue_id ⇒ Object (readonly)
Returns the value of attribute queue_id.
7 8 9 |
# File 'lib/riot_kit/models/riot/match_detail.rb', line 7 def queue_id @queue_id end |
#queue_label ⇒ Object (readonly)
Returns the value of attribute queue_label.
7 8 9 |
# File 'lib/riot_kit/models/riot/match_detail.rb', line 7 def queue_label @queue_label end |
#teams ⇒ Object (readonly)
Returns the value of attribute teams.
7 8 9 |
# File 'lib/riot_kit/models/riot/match_detail.rb', line 7 def teams @teams end |
Instance Method Details
#to_h ⇒ Object
21 22 23 24 25 26 27 28 29 30 31 |
# File 'lib/riot_kit/models/riot/match_detail.rb', line 21 def to_h { match_id: match_id, game_duration_seconds: game_duration_seconds, queue_id: queue_id, queue_label: queue_label, game_creation: game_creation, teams: teams.map(&:to_h), participants: participants.map(&:to_h) } end |