15 std::vector<InstrumentPtr>&& instruments)
16 : m_EventName(eventName)
17 , m_Profiler(profiler)
19 , m_BackendId(backendId)
20 , m_Instruments(
std::move(instruments))
25 : m_EventName(std::move(other.m_EventName))
26 , m_Profiler(other.m_Profiler)
27 , m_Parent(other.m_Parent)
28 , m_BackendId(other.m_BackendId)
29 , m_Instruments(std::move(other.m_Instruments))
40 for (
auto& instrument : m_Instruments)
48 for (
auto& instrument : m_Instruments)
56 std::vector<Measurement> measurements;
57 for (
auto& instrument : m_Instruments)
59 for (
auto& measurement : instrument->GetMeasurements())
61 measurements.emplace_back(std::move(measurement));
94 m_EventName = other.m_EventName;
95 m_Profiler = other.m_Profiler;
96 m_Parent = other.m_Parent;
97 m_BackendId = other.m_BackendId;
98 other.m_Profiler =
nullptr;
99 other.m_Parent =
nullptr;
Event class records measurements reported by BeginEvent()/EndEvent() and returns measurements when Ev...
const Profiler * GetProfiler() const
Get the pointer of the profiler associated with this event.
~Event() noexcept
Destructor.
const std::string & GetName() const
Get the name of the event.
Copyright (c) 2020 ARM Limited.
void Start()
Start the Event.
void Stop()
Stop the Event.
Event & operator=(const Event &other)=delete
Assignment operator.
BackendId GetBackendId() const
Get the backend id of the event.
const std::vector< Measurement > GetMeasurements() const
Get the recorded measurements calculated between Start() and Stop()
Event(const std::string &eventName, Profiler *profiler, Event *parent, const BackendId backendId, std::vector< InstrumentPtr > &&instrument)
const Event * GetParentEvent() const
Get the pointer of the parent event.