Class: Gio::DataInputStream
Instance Method Summary collapse
- #each ⇒ Object (also: #each_line)
- #each_async(io_priority = GLib::PRIORITY_DEFAULT, cancellable = nil, &block) ⇒ Object (also: #each_line_async)
Instance Method Details
#each ⇒ Object Also known as: each_line
19 20 21 22 23 |
# File 'lib/gio2.rb', line 19 def each while line = read_line yield line end end |
#each_async(io_priority = GLib::PRIORITY_DEFAULT, cancellable = nil, &block) ⇒ Object Also known as: each_line_async
27 28 29 30 |
# File 'lib/gio2.rb', line 27 def each_async(io_priority = GLib::PRIORITY_DEFAULT, cancellable = nil, &block) each_async_loop io_priority, cancellable, block self end |