pub unsafe extern "C" fn Dart_CreateIsolateGroupFromKernel(
    script_uri: *const c_char,
    name: *const c_char,
    kernel_buffer: *const u8,
    kernel_buffer_size: isize,
    flags: *mut Dart_IsolateFlags,
    isolate_group_data: *mut c_void,
    isolate_data: *mut c_void,
    error: *mut *mut c_char
) -> Dart_Isolate
Expand description

Creates a new isolate from a Dart Kernel file. The new isolate becomes the current isolate.

Requires there to be no current isolate.

\param script_uri The main source file or snapshot this isolate will load. The VM will provide this URI to the Dart_IsolateGroupCreateCallback when a child isolate is created by Isolate.spawn. The embedder should use a URI that allows it to load the same program into such a child isolate. \param name A short name for the isolate to improve debugging messages. Typically of the format ‘foo.dart:main()’. \param kernel_buffer A buffer which contains a kernel/DIL program. Must remain valid until isolate shutdown. \param kernel_buffer_size The size of kernel_buffer. \param flags Pointer to VM specific flags or NULL for default flags. \param isolate_group_data Embedder group data. This data can be obtained by calling Dart_IsolateGroupData and will be passed to the Dart_IsolateShutdownCallback, Dart_IsolateCleanupCallback, and Dart_IsolateGroupCleanupCallback. \param isolate_data Embedder data. This data will be passed to the Dart_IsolateGroupCreateCallback when new isolates are spawned from this parent isolate. \param error Returns NULL if creation is successful, an error message otherwise. The caller is responsible for calling free() on the error message.

\return The new isolate on success, or NULL if isolate creation failed.