.NET API Reference
Microsoft.JavaScript.NodeApi namespace
public type | description |
---|---|
interface IJSValue<TSelf> | A base interface for a struct that represents a JavaScript value type or a built-in object type. It provides functionality for converting between the struct and JSValue . |
delegate JSActionCallback | Represents a low-level void function or method call or callback from JavaScript into .NET. |
struct JSArray | |
struct JSAsyncIterable | |
struct JSBigInt | |
delegate JSCallback | Represents a low-level function or method call or callback from JavaScript into .NET. |
struct JSCallbackArgs | Provides access to the arguments for a low-level JavaScript function call or callback, along with the this argument and an optional context object. |
struct JSDate | |
class JSDispatcherQueue | |
class JSDispatcherQueueController | |
class JSDispatcherQueueTimer | |
struct JSError | |
enum JSErrorType | |
class JSEventEmitter | Event emitter that can be backed by either a Node.js EventEmitter object or a standalone (runtime-agnostic) listener tracker. |
class JSException | An exception that was caused by an error thrown by JavaScript code or interactions with JavaScript objects. |
class JSExportAttribute | Exports an item to JavaScript, optionally specifying the name of the export and whether it is the default export of the module. |
struct JSFunction | Represents a JavaScript Function value. |
class JSImportAttribute | Indicates a class or struct is imported from JavaScript. |
class JSInvalidThreadAccessException | An exception that was caused by an attempt to access a JavaScript value without any JSValueScope established on the current thread, or from a thread associated with a different environment / root scope. |
struct JSIterable | |
enum JSKeyCollectionMode | |
enum JSKeyConversion | |
[Flags] enum JSKeyFilter | |
struct JSMap | |
struct JSObject | |
struct JSPromise | Represents a JavaScript Promise object. |
[Flags] enum JSPropertyAttributes | |
struct JSPropertyDescriptor | Describes a property of a JavaScript object, including its name, value, and attributes. Can be converted to a JavaScript property descriptor object using the ToObject method. |
struct JSProxy | Enables creation of JS Proxy objects with C# handler callbacks. |
class JSReference | A strong or weak reference to a JS value. |
struct JSSet | |
struct JSSymbol | |
struct JSTypedArray<T> | |
enum JSTypedArrayType | |
struct JSValue | |
class JSValueScope | A scope that controls the lifetime of JS values. When the scope is disposed, any JS values created within the scope are released unless they are held by a strong JSReference . |
class JSValueScopeClosedException | An exception that was caused by an attempt to access a JSValue (or a more specific JS value type, such as JSObject or JSArray ) after its JSValueScope was closed. |
enum JSValueScopeType | Indicates the type of JSValueScope within the hierarchy of scopes. |
enum JSValueType | |
static class NodeApiStatusExtensions | |
static class TaskExtensions | Extension methods for converting between .NET tasks and JS promises. |
Microsoft.JavaScript.NodeApi.Interop namespace
public type | description |
---|---|
struct JSAbortSignal | Represents a JavaScript AbortSignal object and supports conversion to and from CancellationToken. |
struct JSAsyncScope | Helps preventing Node.JS process from exiting while we execute C# async functions. |
struct JSCallbackDescriptor | Descriptor for a callback not associated with an object property, for example a constructor callback or standalone function callback. Enables passing a data object via the callback args data. |
struct JSCallbackOverload | Holds overload resolution information (parameter types) for one of multiple overloads for a .NET method. |
class JSClassBuilder<T> | |
static class JSCollectionExtensions | |
abstract class JSInterface | Base class for a dynamically generated interface adapter that enables a JS object to implement a .NET interface. Holds a reference to the underlying JS value. |
class JSModuleAttribute | Designates a non-static class or static method that initializes the JS module. |
class JSModuleBuilder<T> | Builds JS module exports. |
class JSModuleContext | Manages JavaScript interop context for the lifetime of a .NET module. |
abstract class JSPropertyDescriptorList<TDerived,TObject> | |
class JSRuntimeContext | Manages JavaScript interop context for the lifetime of the .NET Node API host. |
abstract class JSSynchronizationContext | Manages the synchronization context for a JavaScript environment, allowing callbacks and asynchronous continuations to be invoked on the JavaScript thread that runs the environment. |
delegate JSThreadSafeCallback | |
delegate JSThreadSafeFinalizeCallback | |
class JSThreadSafeFunction | |
static class NodeProcess | Provides information about, and control over, the current Node.js process. |
class NodeStream | Represents a Node.js Duplex, Readable, or Writable stream. |
class NodeWorker | A Node.js worker thread, as documented at https://nodejs.org/api/worker_threads.html. |
static class TypeExtensions |
Microsoft.JavaScript.NodeApi.Runtime namespace
public type | description |
---|---|
abstract class JSRuntime | Abstract base class for a JavaScript runtime. |
static class NativeLibrary | Provides APIs for managing native libraries. |
class NodejsEnvironment | A Node.js runtime environment with a dedicated main execution thread. |
class NodejsPlatform | Manages a Node.js platform instance, provided by libnode . |
class NodejsRuntime | |
class TracingJSRuntime | Wraps a JSRuntime and traces all the calls from .NET to JS, including basic inspection of arguments, out values, and return status. |
Microsoft.JavaScript.NodeApi.DotNetHost namespace
public type | description |
---|---|
class JSMarshaller | Generates expressions and delegates that support marshaling between .NET and JS. |
class JSMarshallerException | Exception thrown by JSMarshaller about a failure while dynamically generating marshaling expressions. |
static class JSRuntimeContextExtensions | Extension methods to support importing JavaScript types at runtime. |
class ManagedHost | Supports loading and invoking managed .NET assemblies in a JavaScript process. |
class TypeExporter | Dynamically exports .NET types to JS. |