Sha256: 119391ac32adacfd49820a83d328671352ffdfbd53d741415a80101a08656a7b

Contents?: true

Size: 325 Bytes

Versions: 1

Compression:

Stored size: 325 Bytes

Contents

require 'open-uri'

module SimplePvr
  class ProgrammeIconFetcher
    def self.fetch(url, destination_file)
      Thread.new do
        File.open(destination_file, "wb") do |saved_file|
          open(url, 'rb') do |read_file|
            saved_file.write(read_file.read)
          end
        end
      end
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
simple_pvr-1.1.0 lib/simple_pvr/programme_icon_fetcher.rb