QtList
QList类是一个提供列表的模板类。
Header: | #include <QList> |
qmake: | QT += core |
Inherited By: |
函数:
QList()
QList(const QList<T> &other)
QList(QList<T> &&other)
QList(std::initializer_list<T> args)
~QList()
void append(const T &value)
void append(const QList<T> &value)
const T & at(int i) const
T & back()
const T & back() const
QList::iterator begin()
QList::const_iterator begin() const
QList::const_iterator cbegin() const
QList::const_iterator cend() const
void clear()
QList::const_iterator constBegin() const
QList::const_iterator constEnd() const
const T & constFirst() const
const T & constLast() const
bool contains(const T &value) const
int count(const T &value) const
int count() const
QList::const_reverse_iterator crbegin() const
QList::const_reverse_iterator crend() const
bool empty() const
QList::iterator end()
QList::const_iterator end() const
bool endsWith(const T &value) const
QList::iterator erase(QList::iterator pos)
QList::iterator erase(QList::iterator begin, QList::iterator end)
T & first()
const T & first() const
T & front()
const T & front() const
int indexOf(const T &value, int from = ...) const
void insert(int i, const T &value)
QList::iterator insert(QList::iterator before, const T &value)
bool isEmpty() const
T & last()
const T & last() const
int lastIndexOf(const T &value, int from = ...) const
int length() const
QList<T> mid(int pos, int length = -1) const
void move(int from, int to)
void pop_back()
void pop_front()
void prepend(const T &value)
void push_back(const T &value)
void push_front(const T &value)
QList::reverse_iterator rbegin()
QList::const_reverse_iterator rbegin() const
int removeAll(const T &value)
void removeAt(int i)
void removeFirst()
void removeLast()
bool removeOne(const T &value)
QList::reverse_iterator rend()
QList::const_reverse_iterator rend() const
void replace(int i, const T &value)
void reserve(int alloc)
int size() const
bool startsWith(const T &value) const
void swap(QList<T> &other)
void swap(int i, int j)
T takeAt(int i)
T takeFirst()
T takeLast()
QSet<T> toSet() const
std::list<T> toStdList() const
QVector<T> toVector() const
T value(int i) const
T value(int i, const T &defaultValue) const
bool operator!=(const QList<T> &other) const
QList<T> operator+(const QList<T> &other) const
QList<T> & operator+=(const QList<T> &other)
QList<T> & operator+=(const T &value)
QList<T> & operator<<(const QList<T> &other)
QList<T> & operator<<(const T &value)
QList<T> & operator=(const QList<T> &other)
QList<T> & operator=(QList<T> &&other)
bool operator==(const QList<T> &other) const
T & operator[](int i)
const T & operator[](int i) const
静态公共成员:
QList<T> fromSet(const QSet<T> &set)
QList<T> fromStdList(const std::list<T> &list)
QList<T> fromVector(const QVector<T> &vector)
操作符:
uint qHash(const QList<T> &key, uint seed = ...)
bool operator<(const QList<T> &lhs, const QList<T> &rhs)
QDataStream & operator<<(QDataStream &out, const QList<T> &list)
bool operator<=(const QList<T> &lhs, const QList<T> &rhs)
bool operator>(const QList<T> &lhs, const QList<T> &rhs)
bool operator>=(const QList<T> &lhs, const QList<T> &rhs)
QDataStream & operator>>(QDataStream &in, QList<T> &list)