从输入中解除unicode [英] unescape unicode from input

查看:144
本文介绍了从输入中解除unicode的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用扫描仪从标准输入逐行读取,然后将这些行打印到标准输出。但是,我需要将转义的Unicode字符,如\\\ý转换为实际字符。有任何方法如何做吗?

I am reading line by line from standard input with Scanner, then i print these lines to standard output. But, i need to convert escaped Unicode characters like \u00fd to actual character. Is there any way how to do it?

推荐答案

我建议 http://commons.apache.org/lang/api-2.4/org/apache/commons/lang/StringEscapeUtils .html

这篇关于从输入中解除unicode的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆