Skip to content

scram::xml::Element::Range ​

The range for elements. More...

#include <xml.h>

Public Classes ​

Name
classiterator <br>Iterator over range elements.

Public Types ​

Name
using Elementvalue_type <br>Minimal container for Element type.
using iteratorconst_iterator <br>The container is immutable.

Public Functions ​

Name
iteratorbegin() const<br>The range begin and end iterators.
iteratorend() const
iteratorcbegin() const
iteratorcend() const
Range(const xmlNode * head)<br>Constructs the range for the intrusive list of XML Element nodes.
boolempty() const
std::size_tsize() const

Detailed Description ​

cpp
class scram::xml::Element::Range;

The range for elements.

This is a simple view adaptor to the linked list XML elements.

Public Types Documentation ​

using value_type ​

cpp
using scram::xml::Element::Range::value_type =  Element;

Minimal container for Element type.

using const_iterator ​

cpp
using scram::xml::Element::Range::const_iterator =  iterator;

The container is immutable.

Public Functions Documentation ​

function begin ​

cpp
inline iterator begin() const

The range begin and end iterators.

function end ​

cpp
inline iterator end() const

function cbegin ​

cpp
inline iterator cbegin() const

function cend ​

cpp
inline iterator cend() const

function Range ​

cpp
inline explicit Range(
    const xmlNode * head
)

Constructs the range for the intrusive list of XML Element nodes.

Parameters:

  • head The head node of the list (may be non-Element node!). nullptr if the list is empty.

function empty ​

cpp
inline bool empty() const

Return: true if the range contains no elements.

function size ​

cpp
inline std::size_t size() const

Return: The number of Elements in the list.

Note: O(N) complexity.


Updated on 2025-12-19 at 21:56:46 +0000