internal static IntPtr GetInterface(IStream managedInterface)
{
IntPtr comInterface;
if (managedInterface == null)
return IntPtr.Zero;
#if !RECURSIVE_WRAPPING
else if ((comInterface = NativeToManagedWrapper.GetUnderlyingInterface(managedInterface)) == IntPtr.Zero)
#endif
comInterface = new ManagedToNativeWrapper(managedInterface).comInterface;
return comInterface;
}