MySQL 9.0.0
Source Code Documentation
Discrete_intervals_list Class Reference

List of Discrete_interval objects. More...

#include <discrete_interval.h>

Public Member Functions

 Discrete_intervals_list ()
 
void clear ()
 
void swap (Discrete_intervals_list *other)
 
const Discrete_intervalget_next ()
 
 ~Discrete_intervals_list ()
 
bool append (ulonglong start, ulonglong val, ulonglong incr)
 Appends an interval to the list. More...
 
ulonglong minimum () const
 
ulonglong maximum () const
 
uint nb_elements () const
 

Private Member Functions

void operator= (Discrete_intervals_list &)
 
bool append (Discrete_interval *new_interval)
 
void copy_shallow (const Discrete_intervals_list *other)
 
 Discrete_intervals_list (const Discrete_intervals_list &other)
 

Private Attributes

Discrete_interval first_interval
 To avoid heap allocation in the common case when there is only one interval in the list, we store the first interval here. More...
 
Discrete_intervalhead
 
Discrete_intervaltail
 
Discrete_intervalcurrent
 When many intervals are provided at the beginning of the execution of a statement (in a replication slave or SET INSERT_ID), "current" points to the interval being consumed by the thread now (so "current" goes from "head" to "tail" then to NULL). More...
 
uint elements
 number of elements More...
 

Detailed Description

List of Discrete_interval objects.

Constructor & Destructor Documentation

◆ Discrete_intervals_list() [1/2]

Discrete_intervals_list::Discrete_intervals_list ( const Discrete_intervals_list other)
inlineprivate

◆ Discrete_intervals_list() [2/2]

Discrete_intervals_list::Discrete_intervals_list ( )
inline

◆ ~Discrete_intervals_list()

Discrete_intervals_list::~Discrete_intervals_list ( )
inline

Member Function Documentation

◆ append() [1/2]

bool Discrete_intervals_list::append ( Discrete_interval new_interval)
inlineprivate

◆ append() [2/2]

bool Discrete_intervals_list::append ( ulonglong  start,
ulonglong  val,
ulonglong  incr 
)
inline

Appends an interval to the list.

Parameters
startstart of interval
valhow many values it contains
incrwhat increment between each value
Return values
trueerror
falsesuccess

◆ clear()

void Discrete_intervals_list::clear ( )
inline

◆ copy_shallow()

void Discrete_intervals_list::copy_shallow ( const Discrete_intervals_list other)
inlineprivate

◆ get_next()

const Discrete_interval * Discrete_intervals_list::get_next ( )
inline

◆ maximum()

ulonglong Discrete_intervals_list::maximum ( ) const
inline

◆ minimum()

ulonglong Discrete_intervals_list::minimum ( ) const
inline

◆ nb_elements()

uint Discrete_intervals_list::nb_elements ( ) const
inline

◆ operator=()

void Discrete_intervals_list::operator= ( Discrete_intervals_list )
private

◆ swap()

void Discrete_intervals_list::swap ( Discrete_intervals_list other)
inline

Member Data Documentation

◆ current

Discrete_interval* Discrete_intervals_list::current
private

When many intervals are provided at the beginning of the execution of a statement (in a replication slave or SET INSERT_ID), "current" points to the interval being consumed by the thread now (so "current" goes from "head" to "tail" then to NULL).

◆ elements

uint Discrete_intervals_list::elements
private

number of elements

◆ first_interval

Discrete_interval Discrete_intervals_list::first_interval
private

To avoid heap allocation in the common case when there is only one interval in the list, we store the first interval here.

◆ head

Discrete_interval* Discrete_intervals_list::head
private

◆ tail

Discrete_interval* Discrete_intervals_list::tail
private

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