class Sportradar::Nba::Models::OnCourtPlayer

Public Class Methods

new(attributes = {}) click to toggle source
# File lib/sportradar/nba/models/on_court_player.rb, line 5
def initialize(attributes = {})
  @attributes = attributes
end

Public Instance Methods

event_id() click to toggle source
# File lib/sportradar/nba/models/on_court_player.rb, line 19
def event_id
  @attributes.dig('event_id')
end
full_name() click to toggle source
# File lib/sportradar/nba/models/on_court_player.rb, line 27
def full_name
  @attributes.dig('full_name')
end
player_id() click to toggle source
# File lib/sportradar/nba/models/on_court_player.rb, line 23
def player_id
  @attributes.dig('player_id')
end
team_id() click to toggle source
# File lib/sportradar/nba/models/on_court_player.rb, line 31
def team_id
  @attributes.dig('team_id')
end
team_name() click to toggle source
# File lib/sportradar/nba/models/on_court_player.rb, line 35
def team_name
  @attributes.dig('team_name')
end
to_s() click to toggle source
# File lib/sportradar/nba/models/on_court_player.rb, line 9
def to_s
  [].tap do |sentence_parts|
    sentence_parts << event_id
    sentence_parts << player_id
    sentence_parts << full_name
    sentence_parts << team_id
    sentence_parts << team_name
  end.join(' - ')
end