|
Cutelee
6.1.0
|
A list of Nodes with some convenience API for rendering them. More...
#include <cutelee/node.h>

Public Member Functions | |
| NodeList () | |
| NodeList (const NodeList &list) | |
| NodeList (const QList< Cutelee::Node *> &list) | |
| ~NodeList () | |
| void | append (Cutelee::Node *node) |
| void | append (const QList< Cutelee::Node *> &nodeList) |
| bool | containsNonText () const |
| template<typename T > | |
| QList< T > | findChildren () |
| NodeList & | operator= (const NodeList &list) |
| void | render (OutputStream *stream, Context *c) const |
Public Member Functions inherited from QList< Cutelee::Node *> | |
| QList (const QList< T > &other) | |
| QList (std::initializer_list< T > args) | |
| QList (InputIterator first, InputIterator last) | |
| QList (QList< T > &&other) | |
| void | append (const T &value) |
| void | append (const QList< T > &value) |
| const T & | at (int i) const const |
| T & | back () |
| const T & | back () const const |
| QList::iterator | begin () |
| QList::const_iterator | begin () const const |
| QList::const_iterator | cbegin () const const |
| QList::const_iterator | cend () const const |
| void | clear () |
| QList::const_iterator | constBegin () const const |
| QList::const_iterator | constEnd () const const |
| const T & | constFirst () const const |
| const T & | constLast () const const |
| bool | contains (const T &value) const const |
| int | count (const T &value) const const |
| int | count () const const |
| QList::const_reverse_iterator | crbegin () const const |
| QList::const_reverse_iterator | crend () const const |
| bool | empty () const const |
| QList::iterator | end () |
| QList::const_iterator | end () const const |
| bool | endsWith (const T &value) const const |
| QList::iterator | erase (QList::iterator pos) |
| QList::iterator | erase (QList::iterator begin, QList::iterator end) |
| const T & | first () const const |
| T & | first () |
| T & | front () |
| const T & | front () const const |
| int | indexOf (const T &value, int from) const const |
| void | insert (int i, const T &value) |
| QList::iterator | insert (QList::iterator before, const T &value) |
| bool | isEmpty () const const |
| T & | last () |
| const T & | last () const const |
| int | lastIndexOf (const T &value, int from) const const |
| int | length () const const |
| QList< T > | mid (int pos, int length) const const |
| void | move (int from, int to) |
| bool | operator!= (const QList< T > &other) const const |
| QList< T > | operator+ (const QList< T > &other) const const |
| QList< T > & | operator+= (const QList< T > &other) |
| QList< T > & | operator+= (const T &value) |
| bool | operator< (const QList< T > &lhs, const QList< T > &rhs) |
| QDataStream & | operator<< (QDataStream &out, const QList< T > &list) |
| QList< T > & | operator<< (const QList< T > &other) |
| QList< T > & | operator<< (const T &value) |
| bool | operator<= (const QList< T > &lhs, const QList< T > &rhs) |
| QList< T > & | operator= (QList< T > &&other) |
| QList< T > & | operator= (const QList< T > &other) |
| bool | operator== (const QList< T > &other) const const |
| 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) |
| const T & | operator[] (int i) const const |
| T & | operator[] (int i) |
| void | pop_back () |
| void | pop_front () |
| void | prepend (const T &value) |
| void | push_back (const T &value) |
| void | push_front (const T &value) |
| uint | qHash (const QList< T > &key, uint seed) |
| QList::reverse_iterator | rbegin () |
| QList::const_reverse_iterator | rbegin () const const |
| int | removeAll (const T &value) |
| void | removeAt (int i) |
| void | removeFirst () |
| void | removeLast () |
| bool | removeOne (const T &value) |
| QList::const_reverse_iterator | rend () const const |
| QList::reverse_iterator | rend () |
| void | replace (int i, const T &value) |
| void | reserve (int alloc) |
| int | size () const const |
| bool | startsWith (const T &value) const const |
| void | swap (int i, int j) |
| void | swap (QList< T > &other) |
| void | swapItemsAt (int i, int j) |
| T | takeAt (int i) |
| T | takeFirst () |
| T | takeLast () |
| QSet< T > | toSet () const const |
| std::list< T > | toStdList () const const |
| QVector< T > | toVector () const const |
| T | value (int i) const const |
| T | value (int i, const T &defaultValue) const const |
Additional Inherited Members | |
Static Public Member Functions inherited from QList< Cutelee::Node *> | |
| QList< T > | fromSet (const QSet< T > &set) |
| QList< T > | fromStdList (const std::list< T > &list) |
| QList< T > | fromVector (const QVector< T > &vector) |
Public Attributes inherited from QList< Cutelee::Node *> | |
| typedef | const_pointer |
| typedef | const_reference |
| typedef | const_reverse_iterator |
| typedef | ConstIterator |
| typedef | difference_type |
| typedef | Iterator |
| typedef | pointer |
| typedef | reference |
| typedef | reverse_iterator |
| typedef | size_type |
| typedef | value_type |
Typically, tags which have an end tag will create and later render a list of child nodes.
This class contains API such as append and render to make creating such list easily.
The findChildren method behaves similarly to the QObject::findChildren method, returning a list of nodes of a particular type from the Node objects contained in the list (and their children).
| NodeList::NodeList | ( | const NodeList & | list | ) |
| NodeList::NodeList | ( | const QList< Cutelee::Node *> & | list | ) |
| void NodeList::append | ( | Cutelee::Node * | node | ) |
Appends node to the end of this NodeList.
Definition at line 149 of file node.cpp.
References QList::append().
| void NodeList::append | ( | const QList< Cutelee::Node *> & | nodeList | ) |
Appends nodeList to the end of this NodeList.
Definition at line 160 of file node.cpp.
References QList::append().
| bool NodeList::containsNonText | ( | ) | const |
|
inline |
| void NodeList::render | ( | OutputStream * | stream, |
| Context * | c | ||
| ) | const |
Renders the list of Nodes in the Context c.
Definition at line 177 of file node.cpp.
References QList< Cutelee::Node *>::at(), and QList< Cutelee::Node *>::size().
Referenced by FilterNode::render(), WithNode::render(), WithLocaleNode::render(), SpacelessNode::render(), AutoescapeNode::render(), IfChangedNode::render(), RangeNode::render(), ForNode::render(), BlockNode::render(), and IfEqualNode::render().
1.8.14