btftoolchain
scheduler.h
Go to the documentation of this file.
1 #pragma once
2 
3 #include <string>
4 
5 #include "common.h"
6 
7 namespace btf
8 {
9 
16 class Scheduler
17 {
18  public:
22  enum class Events
23  {
25  schedule,
30  unknown
31  };
32 
38  static std::string eventToString(Events ev);
39 
45  static Events stringToEvent(const std::string& str);
46 };
47 } // namespace btf
Class for Scheduler (SCHED) Events (see BTF Specification Chapter 2.3.4).
Definition: scheduler.h:17
static Events stringToEvent(const std::string &str)
Converts a string into the enum Events.
Definition: scheduler.cpp:21
Events
Possible types of Scheduler events.
Definition: scheduler.h:23
@ schedule
The schedule event indicates that the scheduler (target and source) makes a scheduling decision.
@ unknown
Default value.
static std::string eventToString(Events ev)
Converts the enum Events into string.
Definition: scheduler.cpp:5
Definition: btf.h:43