ACTS
Experiment-independent tracking
Loading...
Searching...
No Matches
Acts::AveragingScopedTimer::Sample Class Reference

RAII wrapper class for measuring individual timing samples. More...

#include <Acts/Utilities/ScopedTimer.hpp>

Public Member Functions

 Sample (AveragingScopedTimer &parent)
 Construct a new sample and start timing.
 Sample (const Sample &)=delete
 Sample (Sample &&) noexcept
 Move constructor that transfers ownership of timing to new sample.
 ~Sample ()
 Record the duration when destroyed.
Sampleoperator= (const Sample &)=delete
Sampleoperator= (Sample &&)=delete

Detailed Description

RAII wrapper class for measuring individual timing samples.

When constructed, starts a timer. When destroyed, automatically records the duration to the parent AveragingScopedTimer.

Constructor & Destructor Documentation

◆ Sample() [1/3]

Acts::AveragingScopedTimer::Sample::Sample ( AveragingScopedTimer & parent)
explicit

Construct a new sample and start timing.

Parameters
parentThe parent averaging scoped timer to record to

◆ ~Sample()

Acts::AveragingScopedTimer::Sample::~Sample ( )

Record the duration when destroyed.

◆ Sample() [2/3]

Acts::AveragingScopedTimer::Sample::Sample ( const Sample & )
delete

◆ Sample() [3/3]

Acts::AveragingScopedTimer::Sample::Sample ( Sample && )
noexcept

Move constructor that transfers ownership of timing to new sample.

Member Function Documentation

◆ operator=() [1/2]

Sample & Acts::AveragingScopedTimer::Sample::operator= ( const Sample & )
delete

◆ operator=() [2/2]

Sample & Acts::AveragingScopedTimer::Sample::operator= ( Sample && )
delete