發新話題

Java 教程《語法說明》Exeception Specifications

Java 教程《語法說明》Exeception Specifications

■ Exeception Specifications
[method-modifiers] returnType methodName( [parameterList] ) throws ExceptionClass1, ExceptonClass2, ‥‥

[說明]
指定 method 可能丟出的 (checked) exceptions。

[範例]
public void read(BufferedReader in) throws IOException { }

TOP

發新話題

本站所有圖文均屬網友發表,僅代表作者的觀點與本站無關,如有侵權請通知版主會盡快刪除。