Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
Loading...
Searching...
No Matches
QBaseIterator< Container > Class Template Reference

\inmodule QtCore QBaseIterator forms the common base class for all iterators operating on subclasses of QIterable. More...

#include <qiterable.h>

+ Inheritance diagram for QBaseIterator< Container >:
+ Collaboration diagram for QBaseIterator< Container >:

Public Member Functions

voidmutableIterator ()
 Returns a non-const pointer to the internal native iterator.
 
const voidconstIterator () const
 Returns a const pointer to the internal native iterator.
 
Container metaContainer () const
 

Protected Member Functions

 QBaseIterator ()=default
 
 QBaseIterator (const QIterable< Container > *iterable, void *iterator)
 
 QBaseIterator (QIterable< Container > *iterable, void *iterator)
 
 QBaseIterator (QBaseIterator &&other)
 
 QBaseIterator (const QBaseIterator &other)
 
 ~QBaseIterator ()
 
QBaseIteratoroperator= (QBaseIterator &&other)
 
QBaseIteratoroperator= (const QBaseIterator &other)
 
QIterable< Container > * mutableIterable () const
 
const QIterable< Container > * constIterable () const
 
void initIterator (const void *copy)
 
void clearIterator ()
 

Detailed Description

template<class Container>
class QBaseIterator< Container >

\inmodule QtCore QBaseIterator forms the common base class for all iterators operating on subclasses of QIterable.

Definition at line 127 of file qiterable.h.

Constructor & Destructor Documentation

◆ QBaseIterator() [1/5]

template<class Container >
QBaseIterator< Container >::QBaseIterator ( )
protecteddefault

◆ QBaseIterator() [2/5]

template<class Container >
template< class Container > QBaseIterator< Container >::QBaseIterator ( const QIterable< Container > * iterable,
void * iterator )
inlineprotected

Creates a const QBaseIterator from an iterable and an iterator.

Definition at line 135 of file qiterable.h.

◆ QBaseIterator() [3/5]

template<class Container >
template< class Container > QBaseIterator< Container >::QBaseIterator ( QIterable< Container > * iterable,
void * iterator )
inlineprotected

Creates a non-const QBaseIterator from an iterable and an iterator.

Definition at line 139 of file qiterable.h.

◆ QBaseIterator() [4/5]

template<class Container >
template< class Container > QBaseIterator< Container >::QBaseIterator ( QBaseIterator< Container > && other)
inlineprotected

Move-constructs a QBaseIterator from other, preserving its const-ness.

Definition at line 143 of file qiterable.h.

References other().

+ Here is the call graph for this function:

◆ QBaseIterator() [5/5]

template<class Container >
template< class Container > QBaseIterator< Container >::QBaseIterator ( const QBaseIterator< Container > & other)
inlineprotected

Copy-constructs a QBaseIterator from other, preserving its const-ness.

Definition at line 149 of file qiterable.h.

References QBaseIterator< Container >::initIterator(), and other().

+ Here is the call graph for this function:

◆ ~QBaseIterator()

template<class Container >
template< class Container > QBaseIterator< Container >::~QBaseIterator ( )
inlineprotected

Destroys a QBaseIterator.

Definition at line 155 of file qiterable.h.

References QBaseIterator< Container >::clearIterator().

+ Here is the call graph for this function:

Member Function Documentation

◆ clearIterator()

template<class Container >
template< class Container > void QBaseIterator< Container >::clearIterator ( )
inlineprotected

Destroys the internal native iterator.

Definition at line 201 of file qiterable.h.

References QBaseIterator< Container >::metaContainer(), and QBaseIterator< Container >::mutableIterable().

Referenced by QBaseIterator< Container >::~QBaseIterator(), QBaseIterator< Container >::operator=(), and QBaseIterator< Container >::operator=().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ constIterable()

template<class Container >
template< class Container > const QIterable * QBaseIterator< Container >::constIterable ( ) const
inlineprotected

Returns a const pointer to the iterable.

Definition at line 183 of file qiterable.h.

References QtPrivate::QConstPreservingPointer< Type, Storage >::constPointer().

Referenced by QBaseIterator< Container >::initIterator(), QBaseIterator< Container >::metaContainer(), QConstIterator< Container >::operator+(), QConstIterator< Container >::operator++(), QConstIterator< Container >::operator-(), and QConstIterator< Container >::operator--().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ constIterator()

template<class Container >
template< class Container > const void * QBaseIterator< Container >::constIterator ( ) const
inline

Returns a const pointer to the internal native iterator.

Definition at line 213 of file qiterable.h.

Referenced by QAssociativeIterator::key(), QAssociativeConstIterator::key(), QConstIterator< Container >::operator!=(), QIterator< Container >::operator!=(), QSequentialConstIterator::operator*(), QConstIterator< Container >::operator-(), QIterator< Container >::operator-(), QConstIterator< Container >::operator==(), QIterator< Container >::operator==(), and QAssociativeConstIterator::value().

+ Here is the caller graph for this function:

◆ initIterator()

template<class Container >
template< class Container > void QBaseIterator< Container >::initIterator ( const void * copy)
inlineprotected

Initializes the internal native iterator by duplicating copy, if given.

Definition at line 188 of file qiterable.h.

References QBaseIterator< Container >::constIterable(), copy(), QBaseIterator< Container >::metaContainer(), and QBaseIterator< Container >::mutableIterable().

Referenced by QBaseIterator< Container >::QBaseIterator(), and QBaseIterator< Container >::operator=().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ metaContainer()

template<class Container >
QMetaContainer QBaseIterator< Container >::metaContainer ( ) const
inline

Returns the meta sequence.

Definition at line 214 of file qiterable.h.

References QBaseIterator< Container >::constIterable().

Referenced by QBaseIterator< Container >::clearIterator(), QBaseIterator< Container >::initIterator(), QAssociativeIterator::key(), QAssociativeConstIterator::key(), QConstIterator< Container >::operator!=(), QIterator< Container >::operator!=(), QAssociativeConstIterator::operator*(), QSequentialConstIterator::operator*(), QIterator< Container >::operator+(), QConstIterator< Container >::operator+(), QIterator< Container >::operator++(), QConstIterator< Container >::operator++(), QIterator< Container >::operator++(), QConstIterator< Container >::operator++(), QIterator< Container >::operator+=(), QConstIterator< Container >::operator+=(), QConstIterator< Container >::operator-(), QIterator< Container >::operator-(), QIterator< Container >::operator-(), QConstIterator< Container >::operator-(), QIterator< Container >::operator--(), QConstIterator< Container >::operator--(), QIterator< Container >::operator--(), QConstIterator< Container >::operator--(), QIterator< Container >::operator-=(), QConstIterator< Container >::operator-=(), QConstIterator< Container >::operator==(), QIterator< Container >::operator==(), QAssociativeIterator::value(), and QAssociativeConstIterator::value().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ mutableIterable()

template<class Container >
template< class Container > QIterable * QBaseIterator< Container >::mutableIterable ( ) const
inlineprotected

Returns a non-const pointer to the iterable, if the original iterable was non-const. Otherwise returns nullptr.

Definition at line 178 of file qiterable.h.

References QtPrivate::QConstPreservingPointer< Type, Storage >::mutablePointer().

Referenced by QBaseIterator< Container >::clearIterator(), QBaseIterator< Container >::initIterator(), QIterator< Container >::operator+(), QIterator< Container >::operator++(), QIterator< Container >::operator-(), and QIterator< Container >::operator--().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ mutableIterator()

template<class Container >
template< class Container > void * QBaseIterator< Container >::mutableIterator ( )
inline

◆ operator=() [1/2]

template<class Container >
template< class Container > QBaseIterator< Container > & QBaseIterator< Container >::operator= ( const QBaseIterator< Container > & other)
inlineprotected

Copy-assigns a QBaseIterator from other, preserving its const-ness.

Definition at line 168 of file qiterable.h.

References QBaseIterator< Container >::clearIterator(), QBaseIterator< Container >::initIterator(), and other().

+ Here is the call graph for this function:

◆ operator=() [2/2]

template<class Container >
template< class Container > QBaseIterator & QBaseIterator< Container >::operator= ( QBaseIterator< Container > && other)
inlineprotected

Move-assigns a QBaseIterator from other, preserving its const-ness.

Definition at line 157 of file qiterable.h.

References QBaseIterator< Container >::clearIterator(), and other().

+ Here is the call graph for this function:

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