This class was introduced in Qt 6.8.
| pointer | |
| reference |
| QDirListing::const_iterator::reference | operator* () const |
| QDirListing::const_iterator & | operator++ () |
| void | operator++ (int) |
| QDirListing::const_iterator::pointer | operator-> () const |
The iterator type returned by QDirListing::cbegin ().
std::move()
d.
std::input_iterator
is partially-formed (a copy of an iterator that has since been advanced), the only valid operations on such an object are destruction and assignment of a new iterator. Therefore the post-increment operator advances the iterator and returns
void
.
const DirEntry &
注意: The "classical" STL algorithms don't support iterator/sentinel, so you need to use C++20 std::ranges algorithms for QDirListing , or else a 3rd-party library that provides range-based algorithms in C++17.
另请参阅 QDirListing , QDirListing::sentinel ,和 QDirListing::DirEntry .
[alias]
const_iterator::
pointer
A typedef for
const QDirListing::DirEntry *
.
[alias]
const_iterator::
reference
A typedef for
const QDirListing::DirEntry &
.
返回
const QDirListing::DirEntry &
of the directory entry this iterator points to.
Pre-increment operator. Advances the iterator and returns a reference to it.
Post-increment operator.
QDirListing::const_iterator models C++20 std::input_iterator , that is, it is a move-only, forward-only, single-pass iterator, that doesn't allow random access.
The return value of post-increment on objects that model
std::input_iterator
is partially-formed (a copy of an iterator that has since been advanced), the only valid operations on such an object are destruction and assignment of a new iterator. Therefore the post-increment operator advances the iterator and returns
void
.
返回
const QDirListing::DirEntry *
to the directory entry this iterator points to.