Class: Rvim::Editor::RedirFile
- Inherits:
-
Object
- Object
- Rvim::Editor::RedirFile
- Defined in:
- lib/rvim/editor.rb
Instance Method Summary collapse
- #<<(msg) ⇒ Object
- #close ⇒ Object
-
#initialize(path, mode) ⇒ RedirFile
constructor
A new instance of RedirFile.
Constructor Details
#initialize(path, mode) ⇒ RedirFile
Returns a new instance of RedirFile.
324 325 326 |
# File 'lib/rvim/editor.rb', line 324 def initialize(path, mode) @file = File.open(path, mode) end |
Instance Method Details
#<<(msg) ⇒ Object
328 329 330 331 |
# File 'lib/rvim/editor.rb', line 328 def <<(msg) @file.puts(msg) @file.flush end |
#close ⇒ Object
333 334 335 |
# File 'lib/rvim/editor.rb', line 333 def close @file.close end |