XsWin32FileStream.Write 方法 | |
Writes a block of bytes to the file stream.
命名空间:
XSharp.IO
程序集:
XSharp.Core (在 XSharp.Core.dll 中) 版本:2.22 GA
语法 VIRTUAL METHOD Write(
bytes AS BYTE[],
offset AS LONG,
count AS LONG
) AS VOID
public override void Write(
byte[] bytes,
int offset,
int count
)
查看代码参数
- bytes
- 类型:Byte
- offset
- 类型:Int32
The zero-based byte offset in array from which to begin copying bytes to the stream. - count
- 类型:Int32
The maximum number of bytes to write.
异常 异常 | 条件 |
---|
ArgumentNullException | array is . |
ArgumentException | offset and count describe an invalid range in array. |
ArgumentOutOfRangeException | offset or count is negative. |
IOException | An I/O error occurred.
-or-
Another thread may have caused an unexpected change in the position of the operating system's file handle. |
ObjectDisposedException | The stream is closed. |
NotSupportedException | The current stream instance does not support writing. |
备注 This method calls the Windows WriteFile() function directly.
参见