java处理文件路径的空格

String configPath=this.getClass().getResource("/").toString().replaceAll("%20", " ");只要这样就可以了,
因为jdk为了编译的时候会把空格变成%20
来自http://blog.sina.com.cn/s/blog_5427beb00100ga7i.html

猜你喜欢

转载自scjingying.iteye.com/blog/1631389