Class: BetterErrors::REPL::Pry::Output
- Inherits:
-
Object
- Object
- BetterErrors::REPL::Pry::Output
- Defined in:
- lib/better_errors/repl/pry.rb
Instance Method Summary collapse
-
#initialize ⇒ Output
constructor
A new instance of Output.
- #puts(*args) ⇒ Object
- #read_buffer ⇒ Object
- #tty? ⇒ Boolean
Constructor Details
#initialize ⇒ Output
Returns a new instance of Output.
14 15 16 |
# File 'lib/better_errors/repl/pry.rb', line 14 def initialize @buffer = "" end |
Instance Method Details
#puts(*args) ⇒ Object
18 19 20 21 22 |
# File 'lib/better_errors/repl/pry.rb', line 18 def puts(*args) args.each do |arg| @buffer << "#{arg.chomp}\n" end end |
#read_buffer ⇒ Object
28 29 30 31 32 |
# File 'lib/better_errors/repl/pry.rb', line 28 def read_buffer @buffer ensure @buffer = "" end |
#tty? ⇒ Boolean
24 25 26 |
# File 'lib/better_errors/repl/pry.rb', line 24 def tty? false end |