StringFromCLSID function Null safety ole32

int StringFromCLSID (
  1. Pointer<GUID> rclsid,
  2. Pointer<Pointer<Utf16>> lplpsz
)

Converts a CLSID into a string of printable characters. Different CLSIDs always convert to different strings.

HRESULT StringFromCLSID(
  REFCLSID rclsid,
  LPOLESTR *lplpsz
);

Implementation

int StringFromCLSID(Pointer<GUID> rclsid, Pointer<Pointer<Utf16>> lplpsz) {
  final _StringFromCLSID = _ole32.lookupFunction<
      Int32 Function(Pointer<GUID> rclsid, Pointer<Pointer<Utf16>> lplpsz),
      int Function(Pointer<GUID> rclsid,
          Pointer<Pointer<Utf16>> lplpsz)>('StringFromCLSID');
  return _StringFromCLSID(rclsid, lplpsz);
}