NativeTarget class final

A native Node-API addon to compile.

Uses the bundled compiler and runtime for the current platform. The entry generates bindings for annotated functions and classes. It also accepts void register(Env env, JsObject exports) or the low-level initialize/afterPump/dispose hooks for explicit registration.

Uses Node's default per-module API behavior. The node constraint checks API availability; it does not opt into newer per-module API behavior.

Inheritance

Constructors

NativeTarget({required File entry, required File output, String? node, File? declarations})
const

Properties

declarations → File?
An optional TypeScript declaration output for annotation-based exports.
final
entry → File
The Dart library to compile.
final
hashCode → int
The hash code for this object.
no setterinherited
node → String?
An optional Node.js compatibility version range.
final
output → File
The output .node file.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited