“常用公式”在线计算,“设计手册”在线查询
分享到:  QQ好友和群QQ好友和群 QQ空间QQ空间 腾讯微博腾讯微博 腾讯朋友腾讯朋友
收藏收藏 分享分享 分享淘帖 支持支持 反对反对

共 1 个关于本帖的回复 最后回复于 2013-8-16 15:01

沙发
曹凯 新来的 发表于 2013-8-16 15:01:32 | 只看该作者
研发埠培训中心
A checked  exception is some subclass of Exception (or Exception itself), excluding  class RuntimeException and its subclasses.Making an exception checked forces  client programmers to deal with the possibility that the exception will be  thrown. eg, IOException thrown by java.io.FileInputStream's read()  method?       Unchecked exceptions are  RuntimeException and any of its subclasses. Class Error and its subclasses  also are unchecked. With an unchecked exception, however, the compiler  doesn't force client programmers either to catch theexception or declare it  in a throws clause. In fact, client programmers may not even know that the  exception could be thrown. eg, StringIndexOutOfBoundsException thrown by  String's charAt() method? Checked exceptions must be caught at compile time.  Runtime exceptions do not need to be. Errors often cannot be.
您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

关注我们

360网站安全检测平台