CreateFileA method

Pointer<Void> CreateFileA(
  1. Pointer<Int8> lpFileName,
  2. int dwDesiredAccess,
  3. int dwShareMode,
  4. Pointer<LPSECURITY_ATTRIBUTES> lpSecurityAttributes,
  5. int dwCreationDisposition,
  6. int dwFlagsAndAttributes,
  7. Pointer<Void> hTemplateFile,
)

Implementation

ffi.Pointer<ffi.Void> CreateFileA(
  ffi.Pointer<ffi.Int8> lpFileName,
  int dwDesiredAccess,
  int dwShareMode,
  ffi.Pointer<LPSECURITY_ATTRIBUTES> lpSecurityAttributes,
  int dwCreationDisposition,
  int dwFlagsAndAttributes,
  ffi.Pointer<ffi.Void> hTemplateFile,
) {
  return (_CreateFileA ??= _dylib
      .lookupFunction<_c_CreateFileA, _dart_CreateFileA>('CreateFileA'))(
    lpFileName,
    dwDesiredAccess,
    dwShareMode,
    lpSecurityAttributes,
    dwCreationDisposition,
    dwFlagsAndAttributes,
    hTemplateFile,
  );
}