GetNamedPipeInfo function Null safety kernel32

int GetNamedPipeInfo(
  1. int hNamedPipe,
  2. Pointer<Uint32> lpFlags,
  3. Pointer<Uint32> lpOutBufferSize,
  4. Pointer<Uint32> lpInBufferSize,
  5. Pointer<Uint32> lpMaxInstances
)

Retrieves information about the specified named pipe.

BOOL GetNamedPipeInfo(
  HANDLE  hNamedPipe,
  LPDWORD lpFlags,
  LPDWORD lpOutBufferSize,
  LPDWORD lpInBufferSize,
  LPDWORD lpMaxInstances);

Implementation

int GetNamedPipeInfo(
    int hNamedPipe,
    Pointer<Uint32> lpFlags,
    Pointer<Uint32> lpOutBufferSize,
    Pointer<Uint32> lpInBufferSize,
    Pointer<Uint32> lpMaxInstances) {
  final _GetNamedPipeInfo = _kernel32.lookupFunction<
      Int32 Function(
          IntPtr hNamedPipe,
          Pointer<Uint32> lpFlags,
          Pointer<Uint32> lpOutBufferSize,
          Pointer<Uint32> lpInBufferSize,
          Pointer<Uint32> lpMaxInstances),
      int Function(
          int hNamedPipe,
          Pointer<Uint32> lpFlags,
          Pointer<Uint32> lpOutBufferSize,
          Pointer<Uint32> lpInBufferSize,
          Pointer<Uint32> lpMaxInstances)>('GetNamedPipeInfo');
  return _GetNamedPipeInfo(
      hNamedPipe, lpFlags, lpOutBufferSize, lpInBufferSize, lpMaxInstances);
}