method

capture

Importance_1
v3.2.13 - Show latest stable - 0 notes - Class: Kernel
capture(stream) public

Captures the given stream and returns it:

stream = capture(:stdout) { puts "Cool" }
stream # => "Cool\n"
Show source
Register or log in to add new notes.