MySQL 8.0.40
Source Code Documentation
ReadView::ids_t Class Reference

This is similar to a std::vector but it is not a drop in replacement. More...

Private Types

typedef trx_ids_t::value_type value_type
 

Private Member Functions

 ids_t ()
 Constructor. More...
 
 ~ids_t ()
 Destructor. More...
 
void reserve (ulint n)
 Try and increase the size of the array. More...
 
void resize (ulint n)
 Resize the array, sets the current element count. More...
 
void clear ()
 Reset the size to 0. More...
 
ulint capacity () const
 
void assign (const value_type *start, const value_type *end)
 Copy and overwrite the current array contents. More...
 
void insert (value_type value)
 Insert the value in the correct slot, preserving the order. More...
 
value_type front () const
 
value_type back () const
 
void push_back (value_type value)
 Append a value to the array. More...
 
trx_id_tdata ()
 
const trx_id_tdata () const
 
ulint size () const
 
bool empty () const
 
 ids_t (const ids_t &)
 
ids_toperator= (const ids_t &)
 

Private Attributes

value_typem_ptr
 Memory for the array. More...
 
ulint m_size
 Number of active elements in the array. More...
 
ulint m_reserved
 Size of m_ptr in elements. More...
 

Friends

class ReadView
 

Detailed Description

This is similar to a std::vector but it is not a drop in replacement.

It is specific to ReadView.

Member Typedef Documentation

◆ value_type

typedef trx_ids_t::value_type ReadView::ids_t::value_type
private

Constructor & Destructor Documentation

◆ ids_t() [1/2]

ReadView::ids_t::ids_t ( )
inlineprivate

Constructor.

◆ ~ids_t()

ReadView::ids_t::~ids_t ( )
inlineprivate

Destructor.

◆ ids_t() [2/2]

ReadView::ids_t::ids_t ( const ids_t )
private

Member Function Documentation

◆ assign()

void ReadView::ids_t::assign ( const value_type start,
const value_type end 
)
private

Copy and overwrite the current array contents.

Copy and overwrite this array contents.

Parameters
startSource array
endPointer to end of array

◆ back()

value_type ReadView::ids_t::back ( ) const
inlineprivate
Returns
the value of the last element in the array

◆ capacity()

ulint ReadView::ids_t::capacity ( ) const
inlineprivate
Returns
the capacity of the array in elements

◆ clear()

void ReadView::ids_t::clear ( )
inlineprivate

Reset the size to 0.

◆ data() [1/2]

trx_id_t * ReadView::ids_t::data ( )
inlineprivate
Returns
a pointer to the start of the array

◆ data() [2/2]

const trx_id_t * ReadView::ids_t::data ( ) const
inlineprivate
Returns
a const pointer to the start of the array

◆ empty()

bool ReadView::ids_t::empty ( ) const
inlineprivate
Returns
true if size() == 0

◆ front()

value_type ReadView::ids_t::front ( ) const
inlineprivate
Returns
the value of the first element in the array

◆ insert()

void ReadView::ids_t::insert ( value_type  value)
private

Insert the value in the correct slot, preserving the order.

Doesn't check for duplicates.

◆ operator=()

ids_t & ReadView::ids_t::operator= ( const ids_t )
private

◆ push_back()

void ReadView::ids_t::push_back ( value_type  value)
private

Append a value to the array.

Parameters
valuethe value to append

◆ reserve()

void ReadView::ids_t::reserve ( ulint  n)
private

Try and increase the size of the array.

Old elements are copied across. It is a no-op if n is < current size.

Parameters
nMake space for n elements

Keep a minimum threshold

◆ resize()

void ReadView::ids_t::resize ( ulint  n)
inlineprivate

Resize the array, sets the current element count.

Parameters
nnew size of the array, in elements

◆ size()

ulint ReadView::ids_t::size ( ) const
inlineprivate
Returns
the number of elements in the array

Friends And Related Function Documentation

◆ ReadView

friend class ReadView
friend

Member Data Documentation

◆ m_ptr

value_type* ReadView::ids_t::m_ptr
private

Memory for the array.

◆ m_reserved

ulint ReadView::ids_t::m_reserved
private

Size of m_ptr in elements.

◆ m_size

ulint ReadView::ids_t::m_size
private

Number of active elements in the array.


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