下列方法声明部分正确的有哪些?
A: public void method() throws Exception
B: public void method() throw Exception
C: public void method() throws IOException
D: public void method() throws RuntimeException
A: public void method() throws Exception
B: public void method() throw Exception
C: public void method() throws IOException
D: public void method() throws RuntimeException
举一反三
- 把方法声明为抽象的公共方法是()? A: public abstract method(); B: public abstract void method(); C: public abstract void method(){} D: public void method()extends abstract
- 下面哪条语句把方法声明为抽象的公共方法?( )。 A: public abstract void method(){} B: public void method() extends abstract C: public abstract method() D: public abstract void method()
- 下面哪条语句把方法声明为抽象的公共方法? A: public abstract method(); B: public abstract void method(); C: public abstract void method(){} D: public void method() extends abstract;
- 下列( )选项不是InputStream类中的方法。 A: public abstract int read( ) throws IOException B: public final void writeInt (int throws IOException C: public void close( )throws IOException D: public int available( )throws IOException
- 49 下面哪条语句把方法声明为抽象的公共方法?() A: public abstract method(); B: public abstract void method(); C: public abstract void method(){} D: public void method() extends abstract;