JSMarshaller.GetFromJSValueDelegate method (1 of 2)
Gets a delegate that converts from a JS value to a specified type.
C#
public Delegate GetFromJSValueDelegate(Type type)
parameter | description |
---|---|
type | The type the value will be converted to. |
Exceptions
exception | condition |
---|---|
NotSupportedException | The type cannot be converted. |
Remarks
Type conversion delegates are built on created and then cached, so it is efficient to call this method multiple times for the same type.
See Also
- class JSMarshaller
- namespace Microsoft.JavaScript.NodeApi.DotNetHost
JSMarshaller.GetFromJSValueDelegate<T> method (2 of 2)
Gets a delegate that converts from a JS value to a specified type.
C#
public To<T> GetFromJSValueDelegate<T>()
parameter | description |
---|---|
T | The type the value will be converted to. |
Exceptions
exception | condition |
---|---|
NotSupportedException | The type cannot be converted. |
Remarks
Type conversion delegates are built on created and then cached, so it is efficient to call this method multiple times for the same type.
See Also
- delegate To<T>
- class JSMarshaller
- namespace Microsoft.JavaScript.NodeApi.DotNetHost