proxygen
ExecutorLoopController.h
Go to the documentation of this file.
1 /*
2  * Copyright 2018-present Facebook, Inc.
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 
17 #pragma once
18 
19 #include <memory>
20 
21 #include <folly/Executor.h>
24 
25 namespace folly {
26 namespace fibers {
27 
32  public:
34  ~ExecutorLoopController() override;
35 
36  private:
40 
41  void setFiberManager(fibers::FiberManager* fm) override;
42  void schedule() override;
43  void runLoop() override;
44  void scheduleThreadSafe() override;
45  void timedSchedule(std::function<void()> func, TimePoint time) override;
46 
47  friend class fibers::FiberManager;
48 };
49 
50 } // namespace fibers
51 } // namespace folly
52 
—— Concurrent Priority Queue Implementation ——
Definition: AtomicBitSet.h:29
void timedSchedule(std::function< void()> func, TimePoint time) override
std::chrono::time_point< Clock > TimePoint
PUSHMI_INLINE_VAR constexpr __adl::get_executor_fn executor
Single-threaded task execution engine.
void setFiberManager(fibers::FiberManager *fm) override
std::chrono::nanoseconds time()