Flutter Engine
The Flutter Engine
fml
platform
darwin
concurrent_message_loop_factory.mm
Go to the documentation of this file.
1
// Copyright 2013 The Flutter Authors. All rights reserved.
2
// Use of this source code is governed by a BSD-style license that can be
3
// found in the LICENSE file.
4
5
#include "flutter/fml/concurrent_message_loop.h"
6
7
namespace
fml
{
8
9
class
ConcurrentMessageLoopDarwin
:
public
ConcurrentMessageLoop
{
10
friend
class
ConcurrentMessageLoop
;
11
12
protected
:
13
explicit
ConcurrentMessageLoopDarwin
(
size_t
worker_count) :
ConcurrentMessageLoop
(worker_count) {}
14
15
void
ExecuteTask
(
const
fml::closure
& task)
override
{
16
@autoreleasepool {
17
task();
18
}
19
}
20
};
21
22
std::shared_ptr<ConcurrentMessageLoop>
ConcurrentMessageLoop::Create
(
size_t
worker_count) {
23
return
std::shared_ptr<ConcurrentMessageLoop>{
new
ConcurrentMessageLoopDarwin(worker_count)};
24
}
25
26
}
// namespace fml
fml::ConcurrentMessageLoopDarwin
Definition:
concurrent_message_loop_factory.mm:9
fml::ConcurrentMessageLoopDarwin::ConcurrentMessageLoopDarwin
ConcurrentMessageLoopDarwin(size_t worker_count)
Definition:
concurrent_message_loop_factory.mm:13
fml::ConcurrentMessageLoopDarwin::ExecuteTask
void ExecuteTask(const fml::closure &task) override
Definition:
concurrent_message_loop_factory.mm:15
fml::ConcurrentMessageLoop
Definition:
concurrent_message_loop.h:22
fml::ConcurrentMessageLoop::Create
static std::shared_ptr< ConcurrentMessageLoop > Create(size_t worker_count=std::thread::hardware_concurrency())
Definition:
concurrent_message_loop_factory.cc:9
fml
Definition:
ascii_trie.cc:9
fml::closure
std::function< void()> closure
Definition:
closure.h:14
Generated on Sun Jun 23 2024 21:54:58 for Flutter Engine by
1.9.4