- 博客(5)
- 收藏
- 关注
原创 【异常处理】If you are using named parameters, ensure that the compiler uses the ‘-parameters‘ flag.
出现异常的代码段:异常信息:异常异常信息中最重要的信息:异常产生原因:JDK 在进行编译时,将元数据进行了重写。解决办法:编译时生成元数据,不进行重写。实现方法: 在代码进行编译时,加上参数 -parameters,即:javac -parameters
2025-03-25 21:16:18
1422
原创 window7 查看端口占用
1、在开始-运行,输入CMD打开命令行界面,输入命令netstat -ano | findstr "80" (注80是你想要看查看的端口号)就会输出包含80端口使用的情况具体对应的行是:协议 本地地址 外部地址 状态 PID2、如果想看某个进程具体是哪个进程可以使用下面命令tasklist | findstr "1
2018-01-11 16:16:14
268
原创 try-with-resources(JDK1.7)
try-with-resources1.不使用try-with-resources关闭资源 public void FileOutputStreamOfTryCatch(){ FileOutputStream out = null; try { out = new FileOutputStream(new File("out.txt"),true); out.write("
2017-12-28 11:29:06
253
原创 java mutil catch(JDK 1.7)
java mutil catch(JDK 1.7)正常的try...catch...语句 @Test public void testTryCatch(){ try{ Integer.parseInt("abc"); int i = 2/0; } catch (ArithmeticException a){ System.out.print
2017-12-28 11:02:11
561
原创 Map集合的相关操作
Collection、Set、List接口都属于单值的操作,即:每次只能操作一个对象,而Map与它们不同的是,每次操作的是一对对象,即二元偶对象,Map中的每个元素都使用key value的形式存储在集合之中,此接口定义如下:1.Map接口中的方法 public void clear() 清空Map集合 public boolean containsKey(Object key)
2016-12-20 10:42:49
558
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人
RSS订阅