Sha256: 37c84eb0da3f82e0803ad7cc919556b031ff14548b537e5ae2aacf92ba2c4f19
Contents?: true
Size: 463 Bytes
Versions: 14
Compression:
Stored size: 463 Bytes
Contents
module SportsDataApi module Mlb class Statistics < JsonData def pitching @pitching ||= orphan_stat :pitching end def fielding @fielding ||= orphan_stat :fielding end def hitting @hitting ||= orphan_stat :hitting end private def orphan_stat(key) return unless statistics.has_key? key MergedStats.new(statistics[key]['overall'], key.to_s) end end end end
Version data entries
14 entries across 14 versions & 1 rubygems