5#ifndef FLUTTER_RUNTIME_DART_VM_H_
6#define FLUTTER_RUNTIME_DART_VM_H_
11#include "flutter/common/settings.h"
12#include "flutter/fml/build_config.h"
13#include "flutter/fml/closure.h"
14#include "flutter/fml/macros.h"
15#include "flutter/fml/memory/ref_counted.h"
16#include "flutter/fml/memory/ref_ptr.h"
17#include "flutter/fml/memory/weak_ptr.h"
18#include "flutter/fml/message_loop.h"
19#include "flutter/lib/ui/isolate_name_server/isolate_name_server.h"
20#include "flutter/runtime/dart_isolate.h"
21#include "flutter/runtime/dart_snapshot.h"
22#include "flutter/runtime/dart_vm_data.h"
23#include "flutter/runtime/service_protocol.h"
24#include "flutter/runtime/skia_concurrent_executor.h"
25#include "third_party/dart/runtime/include/dart_api.h"
105 std::shared_ptr<const DartVMData>
GetVMData()
const;
165 std::shared_ptr<fml::ConcurrentMessageLoop> concurrent_message_loop_;
167 std::shared_ptr<const DartVMData> vm_data_;
168 const std::shared_ptr<IsolateNameServer> isolate_name_server_;
169 const std::shared_ptr<ServiceProtocol> service_protocol_;
174 static std::shared_ptr<DartVM>
Create(
178 std::shared_ptr<IsolateNameServer> isolate_name_server);
180 DartVM(
const std::shared_ptr<const DartVMData>&
data,
181 std::shared_ptr<IsolateNameServer> isolate_name_server);
static sk_sp< Effect > Create()
Represents an instance of a live isolate. An isolate is a separate Dart execution context....
Describes a running instance of the Dart VM. There may only be one running instance of the Dart VM in...
static size_t GetVMLaunchCount()
The number of times the VM has been launched in the process. This call is inherently racy because the...
const Settings & GetSettings() const
The settings used to launch the running VM instance.
std::shared_ptr< const DartVMData > GetVMData() const
The VM and isolate snapshots used by this running Dart VM instance.
std::shared_ptr< IsolateNameServer > GetIsolateNameServer() const
The isolate name server for this running VM instance. The isolate name server maps names (strings) to...
std::shared_ptr< fml::ConcurrentTaskRunner > GetConcurrentWorkerTaskRunner() const
The task runner whose tasks may be executed concurrently on a pool of worker threads....
static bool IsRunningPrecompiledCode()
Checks if VM instances in the process can run precompiled code. This call can be made at any time and...
std::shared_ptr< fml::ConcurrentMessageLoop > GetConcurrentMessageLoop()
The concurrent message loop hosts threads that are used by the engine to perform tasks long running b...
std::shared_ptr< ServiceProtocol > GetServiceProtocol() const
The service protocol instance associated with this running Dart VM instance. This object manages nati...
An interface used by Skia to schedule work on engine managed threads (usually workers in a concurrent...
#define FML_DISALLOW_COPY_AND_ASSIGN(TypeName)
DEF_SWITCHES_START aot vmservice shared library Name of the *so containing AOT compiled Dart assets for launching the service isolate vm snapshot data