QVariant::ConstPointer is a template class that emulates a const pointer to QVariant . 更多...
This class was introduced in Qt 6.11.
| ConstPointer (Pointed && pointed ) | |
| ConstPointer (const Pointed & pointed ) | |
| QVariant::ConstReference<Pointed> | operator* () const |
QVariant::ConstPointer wraps pointed-to value and returns a QVariant::ConstReference to it from its operator*(). This makes it suitable as replacement for an actual pointer. We cannot return an actual pointer from generic iterators as the iterators don't hold an actual QVariant .
[explicit noexcept(...)]
ConstPointer::
ConstPointer
(
Pointed
&&
pointed
)
构造 QVariant::ConstPointer from the value pointed to.
注意:
This function is noexcept when
std::is_nothrow_move_constructible_v<Pointed>
is
true
.
[explicit noexcept(...)]
ConstPointer::
ConstPointer
(const
Pointed
&
pointed
)
构造 QVariant::ConstPointer from the value pointed to.
注意:
This function is noexcept when
std::is_nothrow_copy_constructible_v<Pointed>
is
true
.
[noexcept(...)]
QVariant::ConstReference
<
Pointed
> ConstPointer::
operator*
() const
解引用 QVariant::ConstPointer 到 QVariant::ConstReference .
注意:
This function is noexcept when
std::is_nothrow_copy_constructible_v<Pointed>
is
true
.