fre*_*low 1 java string string-literals
可能重复: 如何将String转换为Java字符串文字?
是否有一个库函数,它接受一个字符串并将其转换为相应的字符串文字?例:
Please say\ask "What?" three times! - > "Please say\\ask \"What?\" three times!"
Please say\ask "What?" three times!
"Please say\\ask \"What?\" three times!"
Pra*_*nti 7
我认为公共语言StringUtils就是这样做的
http://commons.apache.org/proper/commons-lang/apidocs/org/apache/commons/lang3/StringEscapeUtils.html
归档时间:
14 年,5 月 前
查看次数:
1657 次
最近记录:
11 年,4 月 前