Class: String
- Inherits:
-
Object
- Object
- String
- Defined in:
- lib/ext/string.rb
Instance Method Summary collapse
Instance Method Details
#escape ⇒ Object
4 5 6 7 8 |
# File 'lib/ext/string.rb', line 4 def escape newstr = gsub("\n", "\\n") newstr.gsub!('"', '\"') newstr end |