WriteFileGather
C# Signature:
[DllImport("kernel32.dll")]
static extern bool WriteFileGather(IntPtr hFile, [Out] FILE_SEGMENT_ELEMENT []
aSegmentArray, uint nNumberOfBytesToWrite, IntPtr lpReserved,
[In] ref System.Threading.NativeOverlapped lpOverlapped);C# Signature:
[DllImport("kernel32.dll", SetLastError=true)]
static extern unsafe int WriteFileGather(IntPtr hFile,
FILE_SEGMENT_ELEMENT* aSegmentArray, int nNumberOfBytesToWrite,
IntPtr lpReserved, System.Threading.NativeOverlapped* lpOverlapped);User-Defined Types:
[StructLayout(LayoutKind.Explicit, Size = 8)]
internal struct FILE_SEGMENT_ELEMENT
{
[FieldOffset(0)]
public IntPtr Buffer;
[FieldOffset(0)]
public UInt64 Alignment;
}Sample Code:
Última actualización