![](https://img-blog.csdnimg.cn/20201014180756925.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
Java进阶
零零落落。
直截了当,写博客就直言问题,不要前奏不要结语
展开
-
Collections.empty***()的误用
List idsList = new LinkedList(); idsList.add(123546L);List idList = Collections.emptyList(); idList.addAll(idsList); - 此操作异常:java.lang.UnsupportedOperationException当调用集合的addAll()方法时,无论调用者还是被调用者的集合 是原创 2016-12-16 14:35:12 · 257 阅读 · 0 评论 -
java运算符
java中有三种移位运算符a<< : 左移运算符,num << 1,相当于num乘以2b>> : 右移运算符,num >> 1,相当于num除以2c>>> : 无符号右移,忽略符号位,空位都以0补齐转载 2016-12-07 15:09:40 · 559 阅读 · 0 评论 -
Java Runtime.exec()的使用
Java Runtime.exec()的使用 Sun的doc里其实说明还有其他的用法:exec(String[] cmdarray, String[] envp, File dir)Executes the specified command and arguments in a separate process with the specified environment and working转载 2017-03-03 12:08:59 · 409 阅读 · 0 评论