jsNewRuntime function

Pointer<JSRuntime> jsNewRuntime(
  1. _JSChannel callback,
  2. int timeout,
  3. ReceivePort port, {
  4. int? memoryLimit,
})

Implementation

Pointer<JSRuntime> jsNewRuntime(
  _JSChannel callback,
  int timeout,
  ReceivePort port, {
  int? memoryLimit,
}) {
  final rt = _jsNewRuntime(Pointer.fromFunction(channelDispacher), timeout);
  runtimeOpaques[rt] = _RuntimeOpaque(callback, port, memoryLimit);
  return rt;
}