MySQL 9.1.0
Source Code Documentation
Time_based_metric_interface Class Referenceabstract

Abstract class for time based metrics implementations. More...

#include <time_based_metric_interface.h>

Inheritance diagram for Time_based_metric_interface:
[legend]

Public Member Functions

virtual ~Time_based_metric_interface ()=default
 
virtual void reset ()=0
 Resets the counter and summed time to 0. More...
 
virtual void start_timer ()=0
 Starts counting time we are waiting on something. More...
 
virtual void stop_timer ()=0
 Stops the timer for the wait. More...
 
virtual int64_t get_sum_time_elapsed () const =0
 Returns the total time waited across all executions of the start/stop methods, minus the absolute start time of the last one in case it has not ended. More...
 
virtual void increment_counter ()=0
 Increments the waiting counter. More...
 
virtual int64_t get_count () const =0
 Returns the number of times we waited on give spot. More...
 

Detailed Description

Abstract class for time based metrics implementations.

Constructor & Destructor Documentation

◆ ~Time_based_metric_interface()

virtual Time_based_metric_interface::~Time_based_metric_interface ( )
virtualdefault

Member Function Documentation

◆ get_count()

virtual int64_t Time_based_metric_interface::get_count ( ) const
pure virtual

Returns the number of times we waited on give spot.

Returns
the number of times waited

Implemented in Time_based_metric, and Time_based_metric_stub.

◆ get_sum_time_elapsed()

virtual int64_t Time_based_metric_interface::get_sum_time_elapsed ( ) const
pure virtual

Returns the total time waited across all executions of the start/stop methods, minus the absolute start time of the last one in case it has not ended.

Returns
The total time waited, in nanoseconds.

Implemented in Time_based_metric, and Time_based_metric_stub.

◆ increment_counter()

virtual void Time_based_metric_interface::increment_counter ( )
pure virtual

Increments the waiting counter.

Implemented in Time_based_metric, and Time_based_metric_stub.

◆ reset()

virtual void Time_based_metric_interface::reset ( )
pure virtual

Resets the counter and summed time to 0.

Implemented in Time_based_metric, and Time_based_metric_stub.

◆ start_timer()

virtual void Time_based_metric_interface::start_timer ( )
pure virtual

Starts counting time we are waiting on something.

Implemented in Time_based_metric, and Time_based_metric_stub.

◆ stop_timer()

virtual void Time_based_metric_interface::stop_timer ( )
pure virtual

Stops the timer for the wait.

Requires start_timer to be called first

Implemented in Time_based_metric, and Time_based_metric_stub.


The documentation for this class was generated from the following file: