JSClass class
A JavaScript class. Used with JSObjectMake to construct objects with custom behavior.
- Implemented types
- Mixed-in types
-
- AutoDisposeFinalizer
Constructors
- JSClass.create(JSClassDefinition definition)
-
Creates a JavaScript class suitable for use with JSObjectMake.
definition
(JSClassDefinition*) A JSClassDefinition that defines the class.factory
Properties
- hashCode → int
-
The hash code for this object.
no setteroverride
- nativeFinalizer ↔ NativeFinalizer?
-
dart 对象回收器
getter/setter pairinherited
- ref → JSClassRef
-
no setter
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
attach(
Pointer< NativeFinalizerFunction> callback, Pointer<Void> token, {bool autoDispose = true, Object? detach, int? externalSize}) → dynamic -
将引擎持有的指针和 dart 对象回收器绑定。确保 dart 对象销毁的时候,释放引擎持有的指针和资源
inherited
-
detach(
) → dynamic -
将引擎持有的指针和资源释放
inherited
-
free(
) → void - Releases a JavaScript class.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
retain(
) → JSClass - Retains a JavaScript class.
-
toString(
) → String -
A string representation of this object.
override
Operators
-
operator ==(
Object other) → bool -
The equality operator.
override