Class: IO

Inherits:
Object
  • Object
show all
Defined in:
lib/ole/support.rb

Overview

move to support?

Class Method Summary collapse

Class Method Details

.copy(src, dst) ⇒ Object

Copy data from IO-like object src, to dst



57
58
59
60
61
62
# File 'lib/ole/support.rb', line 57

def self.copy src, dst
	until src.eof?
		buf = src.read(4096)
		dst.write buf
	end
end