5#ifndef FLUTTER_RUNTIME_ISOLATE_CONFIGURATION_H_
6#define FLUTTER_RUNTIME_ISOLATE_CONFIGURATION_H_
79 const std::shared_ptr<AssetManager>& asset_manager =
nullptr,
107 std::vector<std::future<std::unique_ptr<const fml::Mapping>>>
123 std::unique_ptr<const fml::Mapping> kernel);
138 std::vector<std::unique_ptr<const fml::Mapping>> kernel_pieces);
Represents an instance of a live isolate. An isolate is a separate Dart execution context....
A read-only Dart heap snapshot, or, read-executable mapping of AOT compiled Dart code.
An isolate configuration is a collection of snapshots and asset managers that the engine will use to ...
bool PrepareIsolate(DartIsolate &isolate)
When an isolate is created and sufficiently initialized to move it into the DartIsolate::Phase::Libra...
virtual bool IsNullSafetyEnabled(const DartSnapshot &snapshot)=0
static std::unique_ptr< IsolateConfiguration > InferFromSettings(const Settings &settings, const std::shared_ptr< AssetManager > &asset_manager=nullptr, const fml::RefPtr< fml::TaskRunner > &io_worker=nullptr, IsolateLaunchType launch_type=IsolateLaunchType::kNewGroup)
Attempts to infer the isolate configuration from the Settings object. If the VM is configured for AOT...
virtual ~IsolateConfiguration()
Destroys an isolate configuration. This has no threading restrictions and may be collection of config...
IsolateConfiguration()
Create an isolate configuration. This has no threading restrictions.
static std::unique_ptr< IsolateConfiguration > CreateForKernelList(std::vector< std::future< std::unique_ptr< const fml::Mapping > > > kernel_pieces)
Creates a JIT isolate configuration using a list of futures to snapshots defining the ready isolate s...
static std::unique_ptr< IsolateConfiguration > CreateForAppSnapshot()
Creates an AOT isolate configuration using snapshot symbols present in the currently loaded process....
static std::unique_ptr< IsolateConfiguration > CreateForKernel(std::unique_ptr< const fml::Mapping > kernel)
Creates a JIT isolate configuration using the specified snapshot. This is a convenience method for th...
virtual bool DoPrepareIsolate(DartIsolate &isolate)=0
#define FML_DISALLOW_COPY_AND_ASSIGN(TypeName)
@ kNewGroup
The isolate is launched as a solo isolate or to start a new group.