Class: IO
- Inherits:
-
Object
- Object
- IO
- Defined in:
- lib/bundler/vendor/thor/lib/thor/core_ext/io_binary_read.rb
Overview
:nodoc:
Instance Method Summary collapse
Instance Method Details
#binread(file, *args) ⇒ Object
3 4 5 6 7 8 |
# File 'lib/bundler/vendor/thor/lib/thor/core_ext/io_binary_read.rb', line 3 def binread(file, *args) fail ArgumentError, "wrong number of arguments (#{1 + args.size} for 1..3)" unless args.size < 3 File.open(file, "rb") do |f| f.read(*args) end end |