Method: MyMatrix#myescape

Defined in:
lib/mymatrix.rb

#myescape(cell) ⇒ Object



467
468
469
470
471
472
473
474
475
# File 'lib/mymatrix.rb', line 467

def myescape(cell)
	o = cell.to_s.dup
	o.gsub!(/"/, '""')		
	if o =~ /[",']/
		#'
		o = "\"#{o}\""
	end
	return o
end