Pie*_*Bos 13 java exception-handling
我遇到了以下方法,令我惊讶的是编译得很好:
private String getControlMessageBlocking() throws ProtocolException,
InterruptedException, IOException {
try {
// <Code that may throw any of the three listed exceptions>
return controlMessage;
} catch (Exception e) {
throw e;
}
}
Run Code Online (Sandbox Code Playgroud)
为什么没有必要Exception被抓住?
| 归档时间: |
|
| 查看次数: |
515 次 |
| 最近记录: |