Class: MLB::PlayerGameBattingStats

Inherits:
Shale::Mapper
  • Object
show all
Defined in:
lib/mlb/player_game_stats.rb

Overview

Represents a player’s batting stats for a game

Instance Attribute Summary collapse

Instance Attribute Details

#at_batsInteger

Returns at bats

Examples:

stats.at_bats #=> 4

Returns:

  • (Integer)

    at bats



22
# File 'lib/mlb/player_game_stats.rb', line 22

attribute :at_bats, Shale::Type::Integer

#base_on_ballsInteger

Returns walks

Examples:

stats.base_on_balls #=> 1

Returns:

  • (Integer)

    walks



86
# File 'lib/mlb/player_game_stats.rb', line 86

attribute :base_on_balls, Shale::Type::Integer

#doublesInteger

Returns doubles

Examples:

stats.doubles #=> 1

Returns:

  • (Integer)

    doubles



46
# File 'lib/mlb/player_game_stats.rb', line 46

attribute :doubles, Shale::Type::Integer

#games_playedInteger

Returns games played

Examples:

stats.games_played #=> 1

Returns:

  • (Integer)

    games played



14
# File 'lib/mlb/player_game_stats.rb', line 14

attribute :games_played, Shale::Type::Integer

#hitsInteger

Returns hits

Examples:

stats.hits #=> 2

Returns:

  • (Integer)

    hits



38
# File 'lib/mlb/player_game_stats.rb', line 38

attribute :hits, Shale::Type::Integer

#home_runsInteger

Returns home runs

Examples:

stats.home_runs #=> 1

Returns:

  • (Integer)

    home runs



62
# File 'lib/mlb/player_game_stats.rb', line 62

attribute :home_runs, Shale::Type::Integer

#rbiInteger

Returns RBIs

Examples:

stats.rbi #=> 3

Returns:

  • (Integer)

    RBIs



70
# File 'lib/mlb/player_game_stats.rb', line 70

attribute :rbi, Shale::Type::Integer

#runsInteger

Returns runs scored

Examples:

stats.runs #=> 1

Returns:

  • (Integer)

    runs



30
# File 'lib/mlb/player_game_stats.rb', line 30

attribute :runs, Shale::Type::Integer

#stolen_basesInteger

Returns stolen bases

Examples:

stats.stolen_bases #=> 0

Returns:

  • (Integer)

    stolen bases



78
# File 'lib/mlb/player_game_stats.rb', line 78

attribute :stolen_bases, Shale::Type::Integer

#strike_outsInteger

Returns strikeouts

Examples:

stats.strike_outs #=> 1

Returns:

  • (Integer)

    strikeouts



94
# File 'lib/mlb/player_game_stats.rb', line 94

attribute :strike_outs, Shale::Type::Integer

#triplesInteger

Returns triples

Examples:

stats.triples #=> 0

Returns:

  • (Integer)

    triples



54
# File 'lib/mlb/player_game_stats.rb', line 54

attribute :triples, Shale::Type::Integer