Module: Erubis::StdoutEnhancer

Included in:
StdoutEruby, StdoutSimplifiedEruby
Defined in:
lib/erubis/enhancer.rb

Overview

use $stdout instead of string

this is only for Eruby.

Class Method Summary collapse

Instance Method Summary collapse

Class Method Details

.descObject

:nodoc:



66
67
68
# File 'lib/erubis/enhancer.rb', line 66

def self.desc   # :nodoc:
  "use $stdout instead of array buffer or string buffer"
end

Instance Method Details

#add_postamble(src) ⇒ Object



74
75
76
# File 'lib/erubis/enhancer.rb', line 74

def add_postamble(src)
  src << "\n''\n"
end

#add_preamble(src) ⇒ Object



70
71
72
# File 'lib/erubis/enhancer.rb', line 70

def add_preamble(src)
  src << "_buf = $stdout;"
end