Sha256: b9d490e2ac753fdd188298fa8ca571d22900fb8a233ab4e651df97f0ed7f3eab

Contents?: true

Size: 527 Bytes

Versions: 1

Compression:

Stored size: 527 Bytes

Contents

module Sportradar
  module Api
    module Football
      class Ncaafb
        class Drive < Sportradar::Api::Football::Drive

          def over?
            plays.last&.parsed_ending
          end

          def handle_plays_and_events(data, **opts)
            create_data(@plays_hash,  data['actions'],  klass: Play,  api: api, game: self) if data['actions']
            create_data(@events_hash, data['events'],   klass: Event, api: api, game: self) if data['events']
          end

        end
      end
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
sportradar-api-0.11.16 lib/sportradar/api/football/ncaafb/drive.rb