|
JavaTM 2 Platform Standard Ed. 6 |
|||||||||
| 上一個類別 下一個類別 | 框架 無框架 | |||||||||
| 摘要: 巢狀 | 欄位 | 建構子 | 方法 | 詳細資訊: 欄位 | 建構子 | 方法 | |||||||||
public interface ObjectOutput
ObjectOutput 擴展 DataOutput 介面以包含物件的寫入操作。DataOutput 套件括基本型別的輸出方法;ObjectOutput 擴展了該介面,以包含物件、陣列和 String 的輸出方法。
InputStream,
ObjectOutputStream,
ObjectInputStream| 方法摘要 | |
|---|---|
void |
close()
關閉該串流。 |
void |
flush()
刷新該串流的緩衝。 |
void |
write(byte[] b)
寫入 byte 陣列。 |
void |
write(byte[] b,
int off,
int len)
寫入位元組的子陣列。 |
void |
write(int b)
寫入位元組。 |
void |
writeObject(Object obj)
將物件寫入底層存儲或串流。 |
| 從介面 java.io.DataOutput 繼承的方法 |
|---|
writeBoolean, writeByte, writeBytes, writeChar, writeChars, writeDouble, writeFloat, writeInt, writeLong, writeShort, writeUTF |
| 方法詳細資訊 |
|---|
void writeObject(Object obj)
throws IOException
obj - 要寫入的物件
IOException - 如果發生任何與常規 Input/Output 相關的異常。
void write(int b)
throws IOException
DataOutput 中的 writeb - 位元組
IOException - 如果發生 I/O 錯誤
void write(byte[] b)
throws IOException
DataOutput 中的 writeb - 要寫入的資料
IOException - 如果發生 I/O 錯誤。
void write(byte[] b,
int off,
int len)
throws IOException
DataOutput 中的 writeb - 要寫入的資料off - 資料中的初始偏移量len - 寫入的位元組數
IOException - 如果發生 I/O 錯誤。
void flush()
throws IOException
IOException - 如果發生 I/O 錯誤。
void close()
throws IOException
IOException - 如果發生 I/O 錯誤。
|
JavaTM 2 Platform Standard Ed. 6 |
|||||||||
| 上一個類別 下一個類別 | 框架 無框架 | |||||||||
| 摘要: 巢狀 | 欄位 | 建構子 | 方法 | 詳細資訊: 欄位 | 建構子 | 方法 | |||||||||
版權所有 2008 Sun Microsystems, Inc. 保留所有權利。請遵守GNU General Public License, version 2 only。