Obsolete Members for QVarLengthArray

クラスQVarLengthArray の以下のメンバは非推奨である。これらは古いソース・コードの動作を維持するために提供されています。新しいコードでは使用しないことを強くお勧めします。

パブリック関数

(deprecated in 6.3) void prepend(T &&value)
(deprecated in 6.3) void prepend(const T &value)

メンバ関数ドキュメント

[deprecated in 6.3] void QVarLengthArray::prepend(T &&value)

[deprecated in 6.3] void QVarLengthArray::prepend(const T &value)

この関数は6.3から非推奨となった。新しいコードでは使わないことを強くお勧めします。

これは遅い。どうしても使いたい場合は、代わりにinsert(cbegin(), ~~~) を使ってください。

value を配列の先頭に挿入します。

これは vector.insert(0,value) と同じです。

大きな配列の場合、vector.insert(0, )は遅い(線形時間)ことがあります。高速なprepend() 関数を提供するコンテナ・クラスが必要な場合は、代わりに std::list を使用してください。

append() およびinsert()も参照

© 2025 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.