CreateProcessWithTokenW method

int CreateProcessWithTokenW(
  1. Pointer<Void> hToken,
  2. int dwLogonFlags,
  3. Pointer<Uint16> lpApplicationName,
  4. Pointer<Uint16> lpCommandLine,
  5. int dwCreationFlags,
  6. Pointer<Void> lpEnvironment,
  7. Pointer<Uint16> lpCurrentDirectory,
  8. Pointer<LPSTARTUPINFOW> lpStartupInfo,
  9. Pointer<LPPROCESS_INFORMATION> lpProcessInformation,
)

Implementation

int CreateProcessWithTokenW(
  ffi.Pointer<ffi.Void> hToken,
  int dwLogonFlags,
  ffi.Pointer<ffi.Uint16> lpApplicationName,
  ffi.Pointer<ffi.Uint16> lpCommandLine,
  int dwCreationFlags,
  ffi.Pointer<ffi.Void> lpEnvironment,
  ffi.Pointer<ffi.Uint16> lpCurrentDirectory,
  ffi.Pointer<LPSTARTUPINFOW> lpStartupInfo,
  ffi.Pointer<LPPROCESS_INFORMATION> lpProcessInformation,
) {
  return (_CreateProcessWithTokenW ??= _dylib.lookupFunction<
      _c_CreateProcessWithTokenW,
      _dart_CreateProcessWithTokenW>('CreateProcessWithTokenW'))(
    hToken,
    dwLogonFlags,
    lpApplicationName,
    lpCommandLine,
    dwCreationFlags,
    lpEnvironment,
    lpCurrentDirectory,
    lpStartupInfo,
    lpProcessInformation,
  );
}