ICoreWebView2DispatchAdapter Interface
Interface to create IDispatch implementing adapter classes for WinRT runtime classes to work with CoreWebView2.AddHostObjectToScript.
Summary
Members | Description |
---|---|
Clean | Release references to WinRT objects used with objects produced from ICoreWebView2DispatchAdapter.WrapObject or ICoreWebView2DispatchAdapter.WrapNamedObject, directly or indirectly, that are no longer necessary to retain. |
UnwrapObject | Given an object returned by ICoreWebView2DispatchAdapter.WrapObject, this method returns the original WinRT object used in the call to ICoreWebView2DispatchAdapter.WrapObject. |
WrapNamedObject | Given a named WinRT namespace, runtimeclass with constructor's name, static API's name, or enum name, this method returns an object that implements IDispatch representing that named entity. |
WrapObject | Given a WinRT object, this method returns an object that implements IDispatch representing that object. |
Methods
Clean
void Clean()
Release references to WinRT objects used with objects produced from ICoreWebView2DispatchAdapter.WrapObject or ICoreWebView2DispatchAdapter.WrapNamedObject, directly or indirectly, that are no longer necessary to retain.
UnwrapObject
Object UnwrapObject(Object wrapped)
Given an object returned by ICoreWebView2DispatchAdapter.WrapObject, this method returns the original WinRT object used in the call to ICoreWebView2DispatchAdapter.WrapObject.
WrapNamedObject
Object WrapNamedObject(string name, ICoreWebView2DispatchAdapter adapter)
Given a named WinRT namespace, runtimeclass with constructor's name, static API's name, or enum name, this method returns an object that implements IDispatch representing that named entity. The adapter parameter is this DispatchAdapter or a parent DispatchAdapter.
WrapObject
Object WrapObject(Object unwrapped, ICoreWebView2DispatchAdapter adapter)
Given a WinRT object, this method returns an object that implements IDispatch representing that object. The adapter parameter is this DispatchAdapter or a parent DispatchAdapter.