System.getProperty("line.separator") 是什么意思?

在java中存在一些转义字符,比如" "为换行符,但是也有一些JDK自带的一些操作符

    比如 : System.getProperty("line.separator")

    这也是换行符,功能和" "是一致的,但是此种写法屏蔽了 Windows和Linux的区别 ,更保险一些.

     学无止境呀!


参考:System.getProperty("line.separator") 是什么意思?

原文地址:https://www.cnblogs.com/aspirant/p/11613589.html