把一个对象写到一个流中相对比较简单,具体是通过调用ObjectOutputStream类的writeObject()方法实现的,那么该方法的定义为( )。
A.public final int writeObject(Object ob throws IOException B.public final void writeObject(Object ob throws IOExcepfion C.public Object writeObject(Object ob throws IOExcepfion D.public final Object writeObject(Object ob throws IOException