java语言-异常处理教材教学课件.pptVIP

  • 0
  • 0
  • 约4.82千字
  • 约 26页
  • 2018-03-14 发布于天津
  • 举报
演示文稿演讲PPT学习教学课件医学文件教学培训课件

* * 异常和异常类 异常处理 创建异常 第六章 异常处理 软件程序肯定会发生错误/问题 what really matters is what happens after the error occurs. How is the error handled? Who handles it? Can the program recover, or should it just die? 从外部问题(硬盘、网络故障等)到编程错误(数组越界、引用空对象等) 致命错误 内存空间不足等错误(Error)导致程序异常中断 程序不能简单地恢复执行 非致命错误 数组越界等异常(Exception)导致程序中断执行 程序在修正后可恢复执行 异常(Exception) Java语言中已定义或用户定义的某个异常类的对象 一个异常类代表一种异常事件 Java语言利用异常来使程序获得处理错误的能力(error-handling) 异常事件(Exceptional Event) An exception is an event that occurs during the execution of a program that disrupts the normal flow of instructions. 异常 Java语言中用来处理异常的类 异常类的方法 构造方法 public Excepti

文档评论(0)

1亿VIP精品文档

相关文档