getHasCurrent method
Determines whether there is a <MainPackageDependency> element at the current position of the enumerator.
Throws a WindowsException on failure.
To learn more, see learn.microsoft.com/windows/win32/api/appxpackaging/nf-appxpackaging-iappxmanifestmainpackagedependenciesenumerator-gethascurrent.
Implementation
bool getHasCurrent() {
final hasCurrent = adaptiveCalloc<Int32>();
final hr$ = HRESULT(_GetHasCurrentFn(ptr, hasCurrent));
if (hr$.isError) {
free(hasCurrent);
throw WindowsException(hr$);
}
final result$ = hasCurrent.value;
free(hasCurrent);
return result$ != FALSE;
}