抛出不能用于错误或未经检查的异常及其子类为什么? [英] Throws cannot be used for error or unchecked exceptions and its sub class why?

查看:59
本文介绍了抛出不能用于错误或未经检查的异常及其子类为什么?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

无法使用 错误或未选中例外情况sub  class 为什么?





我的尝试:



throws不能用于错误或未经检查的异常及其子类为什么?

解决方案

我建议你在网上进行研究,以便你能够理解它。但是,这是一个很好的解释: https://docs.oracle.com/javase/tutorial/ essential / exceptions / runtime.html [ ^ ]

throws cannot be used for error or unchecked exceptions and its sub class why?



What I have tried:

throws cannot be used for error or unchecked exceptions and its sub class why?

解决方案

I suggest you research this online so that you can understand it well. However, here is a good explanation: https://docs.oracle.com/javase/tutorial/essential/exceptions/runtime.html[^]


这篇关于抛出不能用于错误或未经检查的异常及其子类为什么?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆