Class: Sgl::Puts
- Inherits:
-
Object
- Object
- Sgl::Puts
- Defined in:
- lib/sgl/sgl-server.rb
Instance Method Summary collapse
-
#initialize(stream = $stdout) ⇒ Puts
constructor
A new instance of Puts.
- #puts(str) ⇒ Object
Constructor Details
#initialize(stream = $stdout) ⇒ Puts
Returns a new instance of Puts.
10 11 12 13 |
# File 'lib/sgl/sgl-server.rb', line 10 def initialize(stream=$stdout) stream.sync = true @stream = stream end |
Instance Method Details
#puts(str) ⇒ Object
15 16 17 |
# File 'lib/sgl/sgl-server.rb', line 15 def puts(str) @stream.puts(str) end |