Class: Sportradar::Api::Football::StatPack::Punts

Inherits:
Sportradar::Api::Football::StatPack show all
Defined in:
lib/sportradar/api/football/stat_pack/punts.rb

Instance Attribute Summary collapse

Attributes inherited from Sportradar::Api::Football::StatPack

#id, #name, #player, #players, #position, #response

Instance Method Summary collapse

Methods inherited from Sportradar::Api::Football::StatPack

#initialize

Methods inherited from Data

#all_attributes, #attributes, #create_data, #parse_into_array, #parse_into_array_with_options, #parse_out_hashes, #structure_links, #update_data

Constructor Details

This class inherits a constructor from Sportradar::Api::Football::StatPack

Instance Attribute Details

#attemptsObject

Returns the value of attribute attempts.



4
5
6
# File 'lib/sportradar/api/football/stat_pack/punts.rb', line 4

def attempts
  @attempts
end

#avg_net_yardsObject

Returns the value of attribute avg_net_yards.



4
5
6
# File 'lib/sportradar/api/football/stat_pack/punts.rb', line 4

def avg_net_yards
  @avg_net_yards
end

#avg_yardsObject

Returns the value of attribute avg_yards.



4
5
6
# File 'lib/sportradar/api/football/stat_pack/punts.rb', line 4

def avg_yards
  @avg_yards
end

#blockedObject

Returns the value of attribute blocked.



4
5
6
# File 'lib/sportradar/api/football/stat_pack/punts.rb', line 4

def blocked
  @blocked
end

#inside_20Object

Returns the value of attribute inside_20.



4
5
6
# File 'lib/sportradar/api/football/stat_pack/punts.rb', line 4

def inside_20
  @inside_20
end

#longestObject

Returns the value of attribute longest.



4
5
6
# File 'lib/sportradar/api/football/stat_pack/punts.rb', line 4

def longest
  @longest
end

#net_yardsObject

Returns the value of attribute net_yards.



4
5
6
# File 'lib/sportradar/api/football/stat_pack/punts.rb', line 4

def net_yards
  @net_yards
end

#return_yardsObject

Returns the value of attribute return_yards.



4
5
6
# File 'lib/sportradar/api/football/stat_pack/punts.rb', line 4

def return_yards
  @return_yards
end

#touchbacksObject

Returns the value of attribute touchbacks.



4
5
6
# File 'lib/sportradar/api/football/stat_pack/punts.rb', line 4

def touchbacks
  @touchbacks
end

#yardsObject

Returns the value of attribute yards.



4
5
6
# File 'lib/sportradar/api/football/stat_pack/punts.rb', line 4

def yards
  @yards
end

Instance Method Details

#set_statsObject



6
7
8
9
10
11
12
13
14
15
16
17
# File 'lib/sportradar/api/football/stat_pack/punts.rb', line 6

def set_stats
  @avg_yards     = response["avg_yards"] || response['avg']
  @yards         = response["yards"] || response['yds']
  @attempts      = response["attempts"] || response['punts']
  @blocked       = response["blocked"] || response['blk']
  @longest       = response["longest"] || response['lg']
  @touchbacks    = response["touchbacks"] || response['tb']
  @inside_20     = response["inside_20"] || response['in20']
  @avg_net_yards = response["avg_net_yards"] || response['net_avg']
  @return_yards  = response["return_yards"] || response['return_yards']
  @net_yards     = response["net_yards"] # unknown ncaafb
end