LLVM 20.0.0git
Public Types | Public Member Functions | Friends | List of all members
llvm::PagedVector< T, PageSize >::MaterializedIterator Class Reference

Iterator on all the elements of the vector which have actually being constructed. More...

#include "llvm/ADT/PagedVector.h"

Public Types

using iterator_category = std::forward_iterator_tag
 
using value_type = T
 
using difference_type = std::ptrdiff_t
 
using pointer = T *
 
using reference = T &
 

Public Member Functions

 MaterializedIterator (PagedVector const *PV, size_t ElementIdx)
 
MaterializedIteratoroperator++ ()
 Pre-increment operator.
 
MaterializedIterator operator++ (int)
 
T constoperator* () const
 
size_t getIndex () const
 

Friends

bool operator== (const MaterializedIterator &LHS, const MaterializedIterator &RHS)
 Equality operator.
 
bool operator!= (const MaterializedIterator &LHS, const MaterializedIterator &RHS)
 

Detailed Description

template<typename T, size_t PageSize = 1024 / sizeof(T)>
class llvm::PagedVector< T, PageSize >::MaterializedIterator

Iterator on all the elements of the vector which have actually being constructed.

Definition at line 168 of file PagedVector.h.

Member Typedef Documentation

◆ difference_type

template<typename T , size_t PageSize = 1024 / sizeof(T)>
using llvm::PagedVector< T, PageSize >::MaterializedIterator::difference_type = std::ptrdiff_t

Definition at line 175 of file PagedVector.h.

◆ iterator_category

template<typename T , size_t PageSize = 1024 / sizeof(T)>
using llvm::PagedVector< T, PageSize >::MaterializedIterator::iterator_category = std::forward_iterator_tag

Definition at line 173 of file PagedVector.h.

◆ pointer

template<typename T , size_t PageSize = 1024 / sizeof(T)>
using llvm::PagedVector< T, PageSize >::MaterializedIterator::pointer = T *

Definition at line 176 of file PagedVector.h.

◆ reference

template<typename T , size_t PageSize = 1024 / sizeof(T)>
using llvm::PagedVector< T, PageSize >::MaterializedIterator::reference = T &

Definition at line 177 of file PagedVector.h.

◆ value_type

template<typename T , size_t PageSize = 1024 / sizeof(T)>
using llvm::PagedVector< T, PageSize >::MaterializedIterator::value_type = T

Definition at line 174 of file PagedVector.h.

Constructor & Destructor Documentation

◆ MaterializedIterator()

template<typename T , size_t PageSize = 1024 / sizeof(T)>
llvm::PagedVector< T, PageSize >::MaterializedIterator::MaterializedIterator ( PagedVector const PV,
size_t  ElementIdx 
)
inline

Definition at line 179 of file PagedVector.h.

Member Function Documentation

◆ getIndex()

template<typename T , size_t PageSize = 1024 / sizeof(T)>
size_t llvm::PagedVector< T, PageSize >::MaterializedIterator::getIndex ( ) const
inline

Definition at line 218 of file PagedVector.h.

◆ operator*()

template<typename T , size_t PageSize = 1024 / sizeof(T)>
T const & llvm::PagedVector< T, PageSize >::MaterializedIterator::operator* ( ) const
inline

Definition at line 205 of file PagedVector.h.

References assert(), PageSize, and Size.

◆ operator++() [1/2]

template<typename T , size_t PageSize = 1024 / sizeof(T)>
MaterializedIterator & llvm::PagedVector< T, PageSize >::MaterializedIterator::operator++ ( )
inline

Pre-increment operator.

When incrementing the iterator, we skip the elements which have not been materialized yet.

Definition at line 186 of file PagedVector.h.

References PageSize, and Size.

◆ operator++() [2/2]

template<typename T , size_t PageSize = 1024 / sizeof(T)>
MaterializedIterator llvm::PagedVector< T, PageSize >::MaterializedIterator::operator++ ( int  )
inline

Definition at line 199 of file PagedVector.h.

Friends And Related Function Documentation

◆ operator!=

template<typename T , size_t PageSize = 1024 / sizeof(T)>
bool operator!= ( const MaterializedIterator LHS,
const MaterializedIterator RHS 
)
friend

Definition at line 220 of file PagedVector.h.

◆ operator==

template<typename T , size_t PageSize = 1024 / sizeof(T)>
bool operator== ( const MaterializedIterator LHS,
const MaterializedIterator RHS 
)
friend

Equality operator.

Definition at line 213 of file PagedVector.h.


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