Class: Asuka::PreFormatter

Inherits:
Object
  • Object
show all
Defined in:
lib/asuka/formatter.rb

Instance Method Summary collapse

Instance Method Details

#default_stepsObject



41
42
43
# File 'lib/asuka/formatter.rb', line 41

def default_steps
  [:strip, :html_escape]
end

#html_escape(line) ⇒ Object



49
50
51
# File 'lib/asuka/formatter.rb', line 49

def html_escape(line)
  CGI::escapeHTML(line)
end

#strip(line) ⇒ Object



45
46
47
# File 'lib/asuka/formatter.rb', line 45

def strip(line)
  line.strip
end