RandomAccess.Write 方法  
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
重载
| Write(SafeFileHandle, IReadOnlyList<ReadOnlyMemory<Byte>>, Int64) | 
						 将给定缓冲区中的字节序列写入给定偏移量处的给定文件。  | 
        	
| Write(SafeFileHandle, ReadOnlySpan<Byte>, Int64) | 
						 以给定偏移量将给定缓冲区中的字节序列写入给定文件。  | 
        	
Write(SafeFileHandle, IReadOnlyList<ReadOnlyMemory<Byte>>, Int64)
- Source:
 - RandomAccess.cs
 
- Source:
 - RandomAccess.cs
 
- Source:
 - RandomAccess.cs
 
将给定缓冲区中的字节序列写入给定偏移量处的给定文件。
public:
 static void Write(Microsoft::Win32::SafeHandles::SafeFileHandle ^ handle, System::Collections::Generic::IReadOnlyList<ReadOnlyMemory<System::Byte>> ^ buffers, long fileOffset);
	public static void Write (Microsoft.Win32.SafeHandles.SafeFileHandle handle, System.Collections.Generic.IReadOnlyList<ReadOnlyMemory<byte>> buffers, long fileOffset);
	static member Write : Microsoft.Win32.SafeHandles.SafeFileHandle * System.Collections.Generic.IReadOnlyList<ReadOnlyMemory<byte>> * int64 -> unit
	Public Shared Sub Write (handle As SafeFileHandle, buffers As IReadOnlyList(Of ReadOnlyMemory(Of Byte)), fileOffset As Long)
	参数
- handle
 - SafeFileHandle
 
文件句柄。
- buffers
 - IReadOnlyList<ReadOnlyMemory<Byte>>
 
内存缓冲区的列表。 此方法将这些缓冲区的内容复制到 文件中。
- fileOffset
 - Int64
 
要写入的文件位置。
例外
              handle 或 buffers 为 null。
              handle 无效。
文件关闭。
文件不支持查找 (管道或套接字) 。
              fileOffset 为负数。
              handle 未打开写入。
出现 I/O 错误。
注解
文件的位置不是高级的。
适用于
Write(SafeFileHandle, ReadOnlySpan<Byte>, Int64)
- Source:
 - RandomAccess.cs
 
- Source:
 - RandomAccess.cs
 
- Source:
 - RandomAccess.cs
 
以给定偏移量将给定缓冲区中的字节序列写入给定文件。
public:
 static void Write(Microsoft::Win32::SafeHandles::SafeFileHandle ^ handle, ReadOnlySpan<System::Byte> buffer, long fileOffset);
	public static void Write (Microsoft.Win32.SafeHandles.SafeFileHandle handle, ReadOnlySpan<byte> buffer, long fileOffset);
	static member Write : Microsoft.Win32.SafeHandles.SafeFileHandle * ReadOnlySpan<byte> * int64 -> unit
	Public Shared Sub Write (handle As SafeFileHandle, buffer As ReadOnlySpan(Of Byte), fileOffset As Long)
	参数
- handle
 - SafeFileHandle
 
文件句柄。
- buffer
 - ReadOnlySpan<Byte>
 
内存的区域。 此方法将此区域的内容复制到 文件中。
- fileOffset
 - Int64
 
要写入的文件位置。
例外
              handle 为 null。
              handle 无效。
文件关闭。
文件不支持查找 (管道或套接字) 。
              fileOffset 为负数。
              handle 未打开写入。
出现 I/O 错误。
注解
文件的位置不是高级的。