findName method

void findName(
  1. PWSTR szNameBuf,
  2. int lHashVal,
  3. Pointer<VTablePointer> ppTInfo,
  4. Pointer<Int32> rgMemId,
  5. Pointer<Uint16> pcFound,
)

Finds occurrences of a type description in a type library.

This may be used to quickly verify that a name exists in a type library.

Throws a WindowsException on failure.

To learn more, see learn.microsoft.com/windows/win32/api/oaidl/nf-oaidl-itypelib-findname.

Implementation

@pragma('vm:prefer-inline')
void findName(
  PWSTR szNameBuf,
  int lHashVal,
  Pointer<VTablePointer> ppTInfo,
  Pointer<Int32> rgMemId,
  Pointer<Uint16> pcFound,
) {
  final hr$ = HRESULT(
    _FindNameFn(ptr, szNameBuf, lHashVal, ppTInfo, rgMemId, pcFound),
  );
  if (hr$.isError) throw WindowsException(hr$);
}