QWebElementCollection Class ReferenceThe QWebElementCollection class represents a collection of web elements. More... #include <QWebElementCollection> This class is under development and is subject to change. This class was introduced in Qt 4.6. Public Types
Public Functions
Detailed DescriptionThe QWebElementCollection class represents a collection of web elements. Elements in a document can be selected using QWebElement::findAll() or using the QWebElement constructor. The collection is composed by choosing all elements in the document that match a specified CSS selector expression. The number of selected elements is provided through the count() property. Individual elements can be retrieved by index using at(). It is also possible to iterate through all elements in the collection using Qt's foreach macro: QWebElementCollection collection = document.findAll("p"); foreach (QWebElement paraElement, collection) { ... } Member Function DocumentationQWebElementCollection::QWebElementCollection ()Constructs an empty collection. QWebElementCollection::QWebElementCollection ( const QWebElement & contextElement, const QString & query )Constructs a collection of elements from the list of child elements of contextElement that match the specified CSS selector query. QWebElementCollection::QWebElementCollection ( const QWebElementCollection & other )Constructs a copy of other. QWebElementCollection::~QWebElementCollection ()Destroys the collection. void QWebElementCollection::append ( const QWebElementCollection & other )Extends the collection by appending all items of other. The resulting collection may include duplicate elements. See also operator+=(). QWebElement QWebElementCollection::at ( int i ) constReturns the element at index position i in the collection. const_iterator QWebElementCollection::begin () constReturns an STL-style iterator pointing to the first element in the collection. See also end(). iterator QWebElementCollection::begin ()Returns an STL-style iterator pointing to the first element in the collection. See also end(). const_iterator QWebElementCollection::constBegin () constReturns an STL-style iterator pointing to the first element in the collection. See also end(). const_iterator QWebElementCollection::constEnd () constReturns an STL-style iterator pointing to the imaginary element after the last element in the list. See also begin(). int QWebElementCollection::count () constReturns the number of elements in the collection. const_iterator QWebElementCollection::end () constReturns an STL-style iterator pointing to the imaginary element after the last element in the list. See also begin(). iterator QWebElementCollection::end ()Returns an STL-style iterator pointing to the imaginary element after the last element in the list. See also begin(). QWebElement QWebElementCollection::first () constReturns the first element in the collection. See also last(), operator[](), at(), and count(). QWebElement QWebElementCollection::last () constReturns the last element in the collection. See also first(), operator[](), at(), and count(). QList<QWebElement> QWebElementCollection::toList () constReturns a QList object with the elements contained in this collection. QWebElementCollection QWebElementCollection::operator+ ( const QWebElementCollection & other ) constReturns a collection that contains all the elements of this collection followed by all the elements in the other collection. Duplicates may occur in the result. See also operator+=(). QWebElementCollection & QWebElementCollection::operator+= ( const QWebElementCollection & other )Appends the items of the other list to this list and returns a reference to this list. See also operator+() and append(). QWebElementCollection & QWebElementCollection::operator= ( const QWebElementCollection & other )Assigns other to this collection and returns a reference to this collection. QWebElement QWebElementCollection::operator[] ( int position ) constReturns the element at the specified position in the collection. X
|
Попытка перевода Qt документации. Если есть желание присоединиться, или если есть замечания или пожелания, то заходите на форум: Перевод Qt документации на русский язык... Люди внесшие вклад в перевод: Команда переводчиков |