ÿØÿà JFIF    ÿÛ „ ( %!1!%*+...983,7(-.- U:RDoc::AnyMethod[iI"eof:ETI" IO#eof;TF: privateo:RDoc::Markup::Document: @parts[o:RDoc::Markup::Paragraph; [I"OReturns +true+ if the stream is positioned at its end, +false+ otherwise; ;TI".see {Position}[#class-IO-label-Position]:;To:RDoc::Markup::BlankLineo:RDoc::Markup::Verbatim; [ I"f = File.open('t.txt') ;TI" f.eof # => false ;TI"f.seek(0, :END) # => 0 ;TI"f.eof # => true ;T: @format0o; ; [I"BRaises an exception unless the stream is opened for reading; ;TI"&see {Mode}[#class-IO-label-Mode].;T@o; ; [I"?If +self+ is a stream such as pipe or socket, this method ;TI"=blocks until the other end sends some data or closes it:;T@o; ; [I"r, w = IO.pipe ;TI"%Thread.new { sleep 1; w.close } ;TI"-r.eof? # => true # After 1-second wait. ;TI" ;TI"r, w = IO.pipe ;TI"(Thread.new { sleep 1; w.puts "a" } ;TI"/r.eof? # => false # After 1-second wait. ;TI" ;TI"r, w = IO.pipe ;TI"r.eof? # blocks forever ;T; 0o; ; [I"DNote that this method reads data to the input byte buffer. So ;TI"FIO#sysread may not behave as you intend with IO#eof?, unless you ;TI"Dcall IO#rewind first (which is not available for some streams).;T@o; ; [I"#I#eof? is an alias for IO#eof.;T: @fileI" io.c;T:0@omit_headings_from_table_of_contents_below0I"eof -> true or false ;T0[[I" eof?;T@ I"();T@2FI"IO;TcRDoc::NormalClass00