JSCallbackOverload.CreateDescriptor method (1 of 2)
Creates a callback descriptor for a set of method overloads, where the overloads are not loaded until the first call.
C#
public static JSCallbackDescriptor CreateDescriptor(string? name,
Func<JSCallbackOverload[]> deferredOverloads)
parameter | description |
---|---|
name | The method name. |
deferredOverloads | Function that returns an array of objects each having parameter information for one overload. The function is called only once, on the first invocation of the callback. |
Return Value
Callback descriptor that can be used for marshalling the method call.
See Also
- struct JSCallbackDescriptor
- struct JSCallbackOverload
- namespace Microsoft.JavaScript.NodeApi.Interop
JSCallbackOverload.CreateDescriptor method (2 of 2)
Creates a callback descriptor for a set of method overloads.
C#
public static JSCallbackDescriptor CreateDescriptor(string? name, JSCallbackOverload[] overloads)
parameter | description |
---|---|
name | The method name. |
overloads | Array of objects each having parameter information for one overload. |
Return Value
Callback descriptor that can be used for marshalling the method call.
See Also
- struct JSCallbackDescriptor
- struct JSCallbackOverload
- namespace Microsoft.JavaScript.NodeApi.Interop