异常

常见的运行时异常

              NullPointerException- 空指针引用异常

              ClassCastException- 类型强制转换异常。

              IllegalArgumentException- 传递非法参数异常。

              ArithmeticException- 算术运算异常

              ArrayStoreException- 向数组中存放与声明类型不兼容对象异常

              IndexOutOfBoundsException-数组越界异常

              NegativeArraySizeException- 创建一个大小为负数的数组错误异常

              NumberFormatException- 数字格式异常

              SecurityException- 安全异常

              UnsupportedOperationException- 不支持的操作异常

常见的编译时异常

              SQLException  --数据库异常

              IOexception  --IO异常

              FileNotFoundException--文件找不到

              ClassNotFoundException  --类加载异常

              1OFException

              IllegaArguementException 

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章