class Repobrowse::PipeBody
Copyright (C) 2017-2018 all contributors <repobrowse-public@80x24.org> License: AGPL-3.0+ <www.gnu.org/licenses/agpl-3.0.txt>
Attributes
to_io[R]
Public Class Methods
new(io, buf)
click to toggle source
# File lib/repobrowse/pipe_body.rb, line 7 def initialize(io, buf) @to_io = io @buf = buf end
Public Instance Methods
close()
click to toggle source
called by Rack server
# File lib/repobrowse/pipe_body.rb, line 20 def close @buf.clear @to_io.close end
each() { |buf| ... }
click to toggle source
called by Rack server
# File lib/repobrowse/pipe_body.rb, line 13 def each begin yield @buf end while @to_io.read(0x4000, @buf) end