rapidyaml 0.15.2
parse and emit YAML, and do it fast
Loading...
Searching...
No Matches
c4::yml::ConstNodeRef Class Reference

Holds a pointer to an existing tree, and a node id. More...

#include <node.hpp>

Public Types

using tree_type = Tree const

Public Member Functions

construction
 ConstNodeRef () noexcept
 ConstNodeRef (Tree const &t) noexcept
 ConstNodeRef (Tree const *t) noexcept
 ConstNodeRef (Tree const *t, id_type id) noexcept
 ConstNodeRef (std::nullptr_t) noexcept
 ConstNodeRef (ConstNodeRef const &) noexcept=default
 ConstNodeRef (ConstNodeRef &&) noexcept=default
 ConstNodeRef (NodeRef const &) noexcept
 ConstNodeRef (NodeRef &&) noexcept
assignment
ConstNodeRefoperator= (std::nullptr_t) noexcept
ConstNodeRefoperator= (ConstNodeRef const &) noexcept=default
ConstNodeRefoperator= (ConstNodeRef &&) noexcept=default
ConstNodeRefoperator= (NodeRef const &) noexcept
ConstNodeRefoperator= (NodeRef &&) noexcept
member getters
Tree const * tree () const noexcept
id_type id () const noexcept
comparisons
bool operator== (ConstNodeRef const &that) const RYML_NOEXCEPT
bool operator!= (ConstNodeRef const &that) const RYML_NOEXCEPT
node property getters
NodeData const * get () const RYML_NOEXCEPT
 Forward to Tree::type().
hierarchy getters
ConstNodeRef parent () const RYML_NOEXCEPT
 Forward to Tree::parent().
ConstNodeRef first_child () const RYML_NOEXCEPT
 Forward to Tree::first_child().
ConstNodeRef last_child () const RYML_NOEXCEPT
 Forward to Tree::last_child().
ConstNodeRef child (id_type pos) const RYML_NOEXCEPT
 Forward to Tree::child().
ConstNodeRef find_child (csubstr name) const RYML_NOEXCEPT
 Forward to Tree::find_child().
ConstNodeRef prev_sibling () const RYML_NOEXCEPT
 Forward to Tree::prev_sibling().
ConstNodeRef next_sibling () const RYML_NOEXCEPT
 Forward to Tree::next_sibling().
ConstNodeRef first_sibling () const RYML_NOEXCEPT
 Forward to Tree::first_sibling().
ConstNodeRef last_sibling () const RYML_NOEXCEPT
 Forward to Tree::last_sibling().
ConstNodeRef sibling (id_type pos) const RYML_NOEXCEPT
 Forward to Tree::sibling().
ConstNodeRef find_sibling (csubstr name) const RYML_NOEXCEPT
 Forward to Tree::find_sibling().
ConstNodeRef ancestor_doc () const RYML_NOEXCEPT
 Forward to Tree::ancestor_doc().
ConstNodeRef doc (id_type i) const RYML_NOEXCEPT
 Forward to Tree::doc().
square_brackets

operator[]

ConstNodeRef operator[] (csubstr key) const RYML_NOEXCEPT
 Find a child by key; complexity is O(num_children).
ConstNodeRef operator[] (id_type pos) const RYML_NOEXCEPT
 Find a child by position; complexity is O(pos).
at

These functions are the analogue to operator[], with the difference that they emit an error instead of an assertion.

That is, if any of the pre or post conditions is violated, an error is always emitted (resulting in a call to the error callback).

ConstNodeRef at (csubstr key) const
 Get a child by name, with error checking; complexity is O(num_children).
ConstNodeRef at (id_type pos) const
 Get a child by position, with error checking; complexity is O(pos).
node property getters
NodeType type () const RYML_NOEXCEPT
 Forward to Tree::type().
const char * type_str () const RYML_NOEXCEPT
 Forward to Tree::type_str().
csubstr key () const RYML_NOEXCEPT
 Forward to Tree::key().
csubstr key_tag () const RYML_NOEXCEPT
 Forward to Tree::key_tag().
csubstr key_ref () const RYML_NOEXCEPT
 Forward to Tree::key_ref().
csubstr key_anchor () const RYML_NOEXCEPT
 Forward to Tree::key_anchor().
csubstr val () const RYML_NOEXCEPT
 Forward to Tree::val().
csubstr val_tag () const RYML_NOEXCEPT
 Forward to Tree::val_tag().
csubstr val_ref () const RYML_NOEXCEPT
 Forward to Tree::val_ref().
csubstr val_anchor () const RYML_NOEXCEPT
 Forward to Tree::val_anchor().
NodeScalar const & keysc () const RYML_NOEXCEPT
 Forward to Tree::keysc().
NodeScalar const & valsc () const RYML_NOEXCEPT
 Forward to Tree::valsc().
bool key_is_null () const RYML_NOEXCEPT
 Forward to Tree::key_is_null().
bool val_is_null () const RYML_NOEXCEPT
 Forward to Tree::val_is_null().
bool is_key_unfiltered () const noexcept
 Forward to Tree::is_key_unfiltered().
bool is_val_unfiltered () const noexcept
 Forward to Tree::is_val_unfiltered().
node type predicates
bool empty () const RYML_NOEXCEPT
 Forward to Tree::empty().
bool is_stream () const RYML_NOEXCEPT
 Forward to Tree::is_stream().
bool is_doc () const RYML_NOEXCEPT
 Forward to Tree::is_doc().
bool is_container () const RYML_NOEXCEPT
 Forward to Tree::is_container().
bool is_map () const RYML_NOEXCEPT
 Forward to Tree::is_map().
bool is_seq () const RYML_NOEXCEPT
 Forward to Tree::is_seq().
bool has_val () const RYML_NOEXCEPT
 Forward to Tree::has_val().
bool has_key () const RYML_NOEXCEPT
 Forward to Tree::has_key().
bool is_val () const RYML_NOEXCEPT
 Forward to Tree::is_val().
bool is_keyval () const RYML_NOEXCEPT
 Forward to Tree::is_keyval().
bool has_key_tag () const RYML_NOEXCEPT
 Forward to Tree::has_key_tag().
bool has_val_tag () const RYML_NOEXCEPT
 Forward to Tree::has_val_tag().
bool has_key_anchor () const RYML_NOEXCEPT
 Forward to Tree::has_key_anchor().
bool has_val_anchor () const RYML_NOEXCEPT
 Forward to Tree::has_val_anchor().
bool has_anchor () const RYML_NOEXCEPT
 Forward to Tree::has_anchor().
bool is_key_ref () const RYML_NOEXCEPT
 Forward to Tree::is_key_ref().
bool is_val_ref () const RYML_NOEXCEPT
 Forward to Tree::is_val_ref().
bool is_ref () const RYML_NOEXCEPT
 Forward to Tree::is_ref().
bool parent_is_seq () const RYML_NOEXCEPT
 Forward to Tree::parent_is_seq().
bool parent_is_map () const RYML_NOEXCEPT
 Forward to Tree::parent_is_map().
bool is_key_anchor () const noexcept
bool is_val_hanchor () const noexcept
bool is_anchor () const noexcept
bool is_anchor_or_ref () const noexcept
style predicates
bool type_has_any (NodeType_e bits) const RYML_NOEXCEPT
 Forward to Tree::type_has_any().
bool type_has_all (NodeType_e bits) const RYML_NOEXCEPT
 Forward to Tree::type_has_all().
bool type_has_none (NodeType_e bits) const RYML_NOEXCEPT
 Forward to Tree::type_has_none().
NodeType key_style () const RYML_NOEXCEPT
 Forward to Tree::key_style().
NodeType val_style () const RYML_NOEXCEPT
 Forward to Tree::val_style().
bool is_container_styled () const RYML_NOEXCEPT
 Forward to Tree::is_container_styled().
bool is_block () const RYML_NOEXCEPT
 Forward to Tree::is_block().
bool is_flow () const RYML_NOEXCEPT
 Forward to Tree::is_flow().
bool is_flow_sl () const RYML_NOEXCEPT
 Forward to Tree::is_flow_sl().
bool is_flow_ml () const RYML_NOEXCEPT
 Forward to Tree::is_flow_ml1().
bool is_flow_ml1 () const RYML_NOEXCEPT
 Forward to Tree::is_flow_ml1().
bool is_flow_mln () const RYML_NOEXCEPT
 Forward to Tree::is_flow_mln().
bool is_flow_mlx () const RYML_NOEXCEPT
 Forward to Tree::is_flow_mlx().
bool has_flow_space () const RYML_NOEXCEPT
 Forward to Tree::has_flow_space().
bool is_key_styled () const RYML_NOEXCEPT
 Forward to Tree::is_key_styled().
bool is_val_styled () const RYML_NOEXCEPT
 Forward to Tree::is_val_styled().
bool is_key_literal () const RYML_NOEXCEPT
 Forward to Tree::is_key_literal().
bool is_val_literal () const RYML_NOEXCEPT
 Forward to Tree::is_val_literal().
bool is_key_folded () const RYML_NOEXCEPT
 Forward to Tree::is_key_folded().
bool is_val_folded () const RYML_NOEXCEPT
 Forward to Tree::is_val_folded().
bool is_key_squo () const RYML_NOEXCEPT
 Forward to Tree::is_key_squo().
bool is_val_squo () const RYML_NOEXCEPT
 Forward to Tree::is_val_squo().
bool is_key_dquo () const RYML_NOEXCEPT
 Forward to Tree::is_key_dquo().
bool is_val_dquo () const RYML_NOEXCEPT
 Forward to Tree::is_val_dquo().
bool is_key_plain () const RYML_NOEXCEPT
 Forward to Tree::is_key_plain().
bool is_val_plain () const RYML_NOEXCEPT
 Forward to Tree::is_val_plain().
bool is_key_quoted () const RYML_NOEXCEPT
 Forward to Tree::is_key_quoted().
bool is_val_quoted () const RYML_NOEXCEPT
 Forward to Tree::is_val_quoted().
bool is_quoted () const RYML_NOEXCEPT
 Forward to Tree::is_quoted().
hierarchy predicates
bool is_root () const RYML_NOEXCEPT
 Forward to Tree::is_root().
bool has_parent () const RYML_NOEXCEPT
 Forward to Tree::has_parent() Node must be readable.
bool is_ancestor (ConstNodeRef const &ancestor) const RYML_NOEXCEPT
 Forward to Tree::is_ancestor() Node must be readable.
bool has_child (ConstNodeRef const &n) const RYML_NOEXCEPT
 Forward to Tree::has_child().
bool has_children () const RYML_NOEXCEPT
 Forward to Tree::has_children().
bool has_sibling (ConstNodeRef const &n) const RYML_NOEXCEPT
 Forward to Tree::has_sibling().
bool has_other_siblings () const RYML_NOEXCEPT
 Forward to Tree::has_other_siblings().
bool has_siblings () const RYML_NOEXCEPT
hierarchy getters
id_type num_children () const RYML_NOEXCEPT
 O(num_children).
id_type num_siblings () const RYML_NOEXCEPT
 O(num_children).
id_type num_other_siblings () const RYML_NOEXCEPT
 O(num_siblings).
id_type child_pos (ConstNodeRef const &n) const RYML_NOEXCEPT
 O(num_children).
id_type sibling_pos (ConstNodeRef const &n) const RYML_NOEXCEPT
 O(num_siblings).
id_type depth_asc () const RYML_NOEXCEPT
id_type depth_desc () const RYML_NOEXCEPT
 O(log(num_nodes)).
locations

O(num_nodes).

Forward to Tree::depth_desc(). Node must be readable.

Location location (Parser const &parser) const
deserialization
ConstNodeRef const & operator>> (T &v) const
 deserialize the node's val to the given variable, forwarding to the user-overrideable read() function.
bool get_if (csubstr name, T *var) const
 look for a child by name, if it exists assign to var.

Public Attributes

Tree const * m_tree
id_type m_id
friend NodeRef

Friends

struct detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >

iteration

using iterator = detail::child_iterator<ConstNodeRef>
using const_iterator = detail::child_iterator<ConstNodeRef>
using children_view = detail::children_view<ConstNodeRef>
using const_children_view = detail::children_view<ConstNodeRef>
const_iterator begin () const RYML_NOEXCEPT
 get an iterator to the first child
const_iterator cbegin () const RYML_NOEXCEPT
 get an iterator to the first child
const_iterator end () const RYML_NOEXCEPT
 get an iterator to after the last child
const_iterator cend () const RYML_NOEXCEPT
 get an iterator to after the last child
const_children_view children () const RYML_NOEXCEPT
 get an iterable view over children
const_children_view cchildren () const RYML_NOEXCEPT
 get an iterable view over children
const_children_view siblings () const RYML_NOEXCEPT
const_children_view csiblings () const RYML_NOEXCEPT
 get an iterable view over all siblings (including the calling node)

state queries

see NodeRef for an explanation on what these states mean

bool invalid () const noexcept
bool readable () const noexcept
 because a ConstNodeRef cannot be used to write to the tree, readable() has the same meaning as !invalid()
static constexpr bool is_seed () noexcept
 because a ConstNodeRef cannot be used to write to the tree, it can never be a seed.

Detailed Description

Holds a pointer to an existing tree, and a node id.

It can be used only to read from the tree.

Warning
The lifetime of the tree must be larger than that of this object. It is up to the user to ensure that this happens.

Definition at line 477 of file node.hpp.

Member Typedef Documentation

◆ tree_type

Definition at line 481 of file node.hpp.

◆ iterator

using c4::yml::ConstNodeRef::iterator = detail::child_iterator<ConstNodeRef>

Definition at line 710 of file node.hpp.

◆ const_iterator

using c4::yml::ConstNodeRef::const_iterator = detail::child_iterator<ConstNodeRef>

Definition at line 711 of file node.hpp.

◆ children_view

using c4::yml::ConstNodeRef::children_view = detail::children_view<ConstNodeRef>

Definition at line 712 of file node.hpp.

◆ const_children_view

Definition at line 713 of file node.hpp.

Constructor & Destructor Documentation

◆ ConstNodeRef() [1/7]

c4::yml::ConstNodeRef::ConstNodeRef ( )
inlinenoexcept

Definition at line 496 of file node.hpp.

496: m_tree(nullptr), m_id(NONE) {}
Tree const * m_tree
Definition node.hpp:485
@ NONE
an index to none
Definition common.hpp:312

◆ ConstNodeRef() [2/7]

c4::yml::ConstNodeRef::ConstNodeRef ( Tree const & t)
inlinenoexcept

Definition at line 497 of file node.hpp.

497: m_tree(&t), m_id(t .root_id()) {}

◆ ConstNodeRef() [3/7]

c4::yml::ConstNodeRef::ConstNodeRef ( Tree const * t)
inlinenoexcept

Definition at line 498 of file node.hpp.

498: m_tree(t ), m_id(t->root_id()) {}

◆ ConstNodeRef() [4/7]

c4::yml::ConstNodeRef::ConstNodeRef ( Tree const * t,
id_type id )
inlinenoexcept

Definition at line 499 of file node.hpp.

499: m_tree(t), m_id(id) {}

◆ ConstNodeRef() [5/7]

c4::yml::ConstNodeRef::ConstNodeRef ( std::nullptr_t )
inlinenoexcept

Definition at line 500 of file node.hpp.

500: m_tree(nullptr), m_id(NONE) {}

◆ ConstNodeRef() [6/7]

c4::yml::ConstNodeRef::ConstNodeRef ( ConstNodeRef const & )
defaultnoexcept

◆ ConstNodeRef() [7/7]

c4::yml::ConstNodeRef::ConstNodeRef ( ConstNodeRef && )
defaultnoexcept

Member Function Documentation

◆ operator=() [1/3]

ConstNodeRef & c4::yml::ConstNodeRef::operator= ( std::nullptr_t )
inlinenoexcept

Definition at line 515 of file node.hpp.

515{ m_tree = nullptr; m_id = NONE; return *this; }

◆ operator=() [2/3]

ConstNodeRef & c4::yml::ConstNodeRef::operator= ( ConstNodeRef const & )
defaultnoexcept

◆ operator=() [3/3]

ConstNodeRef & c4::yml::ConstNodeRef::operator= ( ConstNodeRef && )
defaultnoexcept

◆ invalid()

bool c4::yml::ConstNodeRef::invalid ( ) const
inlinenoexcept

Definition at line 532 of file node.hpp.

532{ return (!m_tree) || (m_id == NONE); }

◆ readable()

bool c4::yml::ConstNodeRef::readable ( ) const
inlinenoexcept

because a ConstNodeRef cannot be used to write to the tree, readable() has the same meaning as !invalid()

Definition at line 535 of file node.hpp.

535{ return m_tree != nullptr && m_id != NONE; }

◆ is_seed()

constexpr bool c4::yml::ConstNodeRef::is_seed ( )
inlinestaticconstexprnoexcept

because a ConstNodeRef cannot be used to write to the tree, it can never be a seed.

This method is provided for API equivalence between ConstNodeRef and NodeRef.

Definition at line 538 of file node.hpp.

538{ return false; }

◆ tree()

Tree const * c4::yml::ConstNodeRef::tree ( ) const
inlinenoexcept

Definition at line 563 of file node.hpp.

563{ return m_tree; }

◆ id()

id_type c4::yml::ConstNodeRef::id ( ) const
inlinenoexcept

Definition at line 564 of file node.hpp.

564{ return m_id; }

◆ operator==()

bool c4::yml::ConstNodeRef::operator== ( ConstNodeRef const & that) const
inline

Definition at line 573 of file node.hpp.

573{ return that.m_tree == m_tree && m_id == that.m_id; }

◆ operator!=()

bool c4::yml::ConstNodeRef::operator!= ( ConstNodeRef const & that) const
inline

Definition at line 574 of file node.hpp.

574{ return ! this->operator== (that); }
bool operator==(ConstNodeRef const &that) const RYML_NOEXCEPT
Definition node.hpp:573

◆ get()

NodeData const * c4::yml::ConstNodeRef::get ( ) const
inline

Forward to Tree::type().

Node must be readable.

Definition at line 583 of file node.hpp.

◆ parent()

ConstNodeRef c4::yml::ConstNodeRef::parent ( ) const
inline

Forward to Tree::parent().

Node must be readable.

Definition at line 595 of file node.hpp.

◆ first_child()

ConstNodeRef c4::yml::ConstNodeRef::first_child ( ) const
inline

Forward to Tree::first_child().

Node must be readable.

Definition at line 596 of file node.hpp.

◆ last_child()

ConstNodeRef c4::yml::ConstNodeRef::last_child ( ) const
inline

Forward to Tree::last_child().

Node must be readable.

Definition at line 597 of file node.hpp.

◆ child()

ConstNodeRef c4::yml::ConstNodeRef::child ( id_type pos) const
inline

Forward to Tree::child().

Node must be readable.

Definition at line 598 of file node.hpp.

◆ find_child()

ConstNodeRef c4::yml::ConstNodeRef::find_child ( csubstr name) const
inline

Forward to Tree::find_child().

Node must be readable.

Definition at line 599 of file node.hpp.

◆ prev_sibling()

ConstNodeRef c4::yml::ConstNodeRef::prev_sibling ( ) const
inline

Forward to Tree::prev_sibling().

Node must be readable.

Definition at line 600 of file node.hpp.

◆ next_sibling()

ConstNodeRef c4::yml::ConstNodeRef::next_sibling ( ) const
inline

Forward to Tree::next_sibling().

Node must be readable.

Definition at line 601 of file node.hpp.

◆ first_sibling()

ConstNodeRef c4::yml::ConstNodeRef::first_sibling ( ) const
inline

Forward to Tree::first_sibling().

Node must be readable.

Definition at line 602 of file node.hpp.

◆ last_sibling()

ConstNodeRef c4::yml::ConstNodeRef::last_sibling ( ) const
inline

Forward to Tree::last_sibling().

Node must be readable.

Definition at line 603 of file node.hpp.

◆ sibling()

ConstNodeRef c4::yml::ConstNodeRef::sibling ( id_type pos) const
inline

Forward to Tree::sibling().

Node must be readable.

Definition at line 604 of file node.hpp.

◆ find_sibling()

ConstNodeRef c4::yml::ConstNodeRef::find_sibling ( csubstr name) const
inline

Forward to Tree::find_sibling().

Node must be readable.

Definition at line 605 of file node.hpp.

◆ ancestor_doc()

ConstNodeRef c4::yml::ConstNodeRef::ancestor_doc ( ) const
inline

Forward to Tree::ancestor_doc().

Node must be readable.

Definition at line 606 of file node.hpp.

◆ doc()

ConstNodeRef c4::yml::ConstNodeRef::doc ( id_type i) const
inline

Forward to Tree::doc().

Node must be readable. succeeds even when the node may have invalid or seed id

Definition at line 607 of file node.hpp.

◆ operator[]() [1/2]

ConstNodeRef c4::yml::ConstNodeRef::operator[] ( csubstr key) const
inline

Find a child by key; complexity is O(num_children).

Behaves similar to the non-const overload, but further asserts that the returned node is readable (because it can never be in a seed state). The assertion is performed only if RYML_USE_ASSERT is set to true. As with the non-const overload, it is UB to use the return value if it is not valid.

See also
https://github.com/biojppm/rapidyaml/issues/389

Definition at line 626 of file node.hpp.

627 {
628 assert_readable_();
629 id_type ch = m_tree->find_child(m_id, key);
630 _RYML_ASSERT_VISIT_(m_tree->m_callbacks, ch != NONE, m_tree, m_id);
631 return {m_tree, ch};
632 }
RYML_ID_TYPE id_type
The type of a node id in the YAML tree; to override the default type, define the macro RYML_ID_TYPE t...
Definition common.hpp:305

◆ operator[]() [2/2]

ConstNodeRef c4::yml::ConstNodeRef::operator[] ( id_type pos) const
inline

Find a child by position; complexity is O(pos).

Behaves similar to the non-const overload, but further asserts that the returned node is readable (because it can never be in a seed state). This assertion is performed only if RYML_USE_ASSERT is set to true. As with the non-const overload, it is UB to use the return value if it is not valid.

See also
https://github.com/biojppm/rapidyaml/issues/389

Definition at line 643 of file node.hpp.

644 {
645 assert_readable_();
646 id_type ch = m_tree->child(m_id, pos);
647 _RYML_ASSERT_VISIT_(m_tree->m_callbacks, ch != NONE, m_tree, m_id);
648 return {m_tree, ch};
649 }

◆ at() [1/2]

ConstNodeRef c4::yml::ConstNodeRef::at ( csubstr key) const
inline

Get a child by name, with error checking; complexity is O(num_children).

Behaves as operator[](csubstr) const, but always raises an error (even when RYML_USE_ASSERT is set to false) when the returned node does not exist, or when this node is not readable, or when it is not a map. This behaviour is similar to std::vector::at(), but the error consists in calling the error callback instead of directly raising an exception.

Definition at line 674 of file node.hpp.

675 {
676 check_readable_();
677 _RYML_CHECK_VISIT_(m_tree->m_callbacks, m_tree->is_map(m_id), m_tree, m_id);
678 id_type ch = m_tree->find_child(m_id, key);
679 _RYML_CHECK_VISIT_(m_tree->m_callbacks, ch != NONE, m_tree, m_id);
680 return {m_tree, ch};
681 }

◆ at() [2/2]

ConstNodeRef c4::yml::ConstNodeRef::at ( id_type pos) const
inline

Get a child by position, with error checking; complexity is O(pos).

Behaves as operator[](id_type) const, but always raises an error (even when RYML_USE_ASSERT is set to false) when the returned node does not exist, or when this node is not readable, or when it is not a container. This behaviour is similar to std::vector::at(), but the error consists in calling the error callback instead of directly raising an exception.

Definition at line 692 of file node.hpp.

693 {
694 check_readable_();
695 const id_type cap = m_tree->capacity();
696 _RYML_CHECK_VISIT_(m_tree->m_callbacks, (pos >= 0 && pos < cap), m_tree, m_id);
697 _RYML_CHECK_VISIT_(m_tree->m_callbacks, m_tree->is_container(m_id), m_tree, m_id);
698 const id_type ch = m_tree->child(m_id, pos);
699 _RYML_CHECK_VISIT_(m_tree->m_callbacks, ch != NONE, m_tree, m_id);
700 return {m_tree, ch};
701 }

◆ begin()

const_iterator c4::yml::ConstNodeRef::begin ( ) const
inline

get an iterator to the first child

Definition at line 716 of file node.hpp.

◆ cbegin()

const_iterator c4::yml::ConstNodeRef::cbegin ( ) const
inline

get an iterator to the first child

Definition at line 717 of file node.hpp.

◆ end()

const_iterator c4::yml::ConstNodeRef::end ( ) const
inline

get an iterator to after the last child

Definition at line 719 of file node.hpp.

◆ cend()

const_iterator c4::yml::ConstNodeRef::cend ( ) const
inline

get an iterator to after the last child

Definition at line 720 of file node.hpp.

◆ children()

const_children_view c4::yml::ConstNodeRef::children ( ) const
inline

get an iterable view over children

Definition at line 723 of file node.hpp.

◆ cchildren()

const_children_view c4::yml::ConstNodeRef::cchildren ( ) const
inline

get an iterable view over children

Definition at line 724 of file node.hpp.

◆ siblings()

const_children_view c4::yml::ConstNodeRef::siblings ( ) const
inline

Definition at line 726 of file node.hpp.

726{ assert_readable_(); return detail::make_siblings_view<const_children_view>(m_tree, m_id); } /** get an iterable view over all siblings (including the calling node) */

◆ csiblings()

const_children_view c4::yml::ConstNodeRef::csiblings ( ) const
inline

get an iterable view over all siblings (including the calling node)

Definition at line 727 of file node.hpp.

727{ assert_readable_(); return detail::make_siblings_view<const_children_view>(m_tree, m_id); } /** get an iterable view over all siblings (including the calling node) */

◆ type()

Forward to Tree::type().

Node must be readable.

Definition at line 194 of file node.hpp.

◆ type_str()

const char * c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::type_str ( ) const
inlineinherited

Forward to Tree::type_str().

Node must be readable.

Definition at line 195 of file node.hpp.

◆ key()

Forward to Tree::key().

Node must be readable.

Definition at line 197 of file node.hpp.

◆ key_tag()

csubstr c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::key_tag ( ) const
inlineinherited

Forward to Tree::key_tag().

Node must be readable.

Definition at line 198 of file node.hpp.

◆ key_ref()

csubstr c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::key_ref ( ) const
inlineinherited

Forward to Tree::key_ref().

Node must be readable.

Definition at line 199 of file node.hpp.

◆ key_anchor()

csubstr c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::key_anchor ( ) const
inlineinherited

Forward to Tree::key_anchor().

Node must be readable.

Definition at line 200 of file node.hpp.

◆ val()

Forward to Tree::val().

Node must be readable.

Definition at line 202 of file node.hpp.

◆ val_tag()

csubstr c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::val_tag ( ) const
inlineinherited

Forward to Tree::val_tag().

Node must be readable.

Definition at line 203 of file node.hpp.

◆ val_ref()

csubstr c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::val_ref ( ) const
inlineinherited

Forward to Tree::val_ref().

Node must be readable.

Definition at line 204 of file node.hpp.

◆ val_anchor()

csubstr c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::val_anchor ( ) const
inlineinherited

Forward to Tree::val_anchor().

Node must be readable.

Definition at line 205 of file node.hpp.

◆ keysc()

NodeScalar const & c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::keysc ( ) const
inlineinherited

Forward to Tree::keysc().

Node must be readable.

Definition at line 207 of file node.hpp.

◆ valsc()

NodeScalar const & c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::valsc ( ) const
inlineinherited

Forward to Tree::valsc().

Node must be readable.

Definition at line 208 of file node.hpp.

◆ key_is_null()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::key_is_null ( ) const
inlineinherited

Forward to Tree::key_is_null().

Node must be readable.

Definition at line 210 of file node.hpp.

◆ val_is_null()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::val_is_null ( ) const
inlineinherited

Forward to Tree::val_is_null().

Node must be readable.

Definition at line 211 of file node.hpp.

◆ is_key_unfiltered()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_key_unfiltered ( ) const
inlinenoexceptinherited

Forward to Tree::is_key_unfiltered().

Node must be readable.

Definition at line 213 of file node.hpp.

◆ is_val_unfiltered()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_val_unfiltered ( ) const
inlinenoexceptinherited

Forward to Tree::is_val_unfiltered().

Node must be readable.

Definition at line 214 of file node.hpp.

◆ empty()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::empty ( ) const
inlineinherited

Forward to Tree::empty().

Node must be readable.

Definition at line 223 of file node.hpp.

◆ is_stream()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_stream ( ) const
inlineinherited

Forward to Tree::is_stream().

Node must be readable.

Definition at line 224 of file node.hpp.

◆ is_doc()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_doc ( ) const
inlineinherited

Forward to Tree::is_doc().

Node must be readable.

Definition at line 225 of file node.hpp.

◆ is_container()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_container ( ) const
inlineinherited

Forward to Tree::is_container().

Node must be readable.

Definition at line 226 of file node.hpp.

◆ is_map()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_map ( ) const
inlineinherited

Forward to Tree::is_map().

Node must be readable.

Definition at line 227 of file node.hpp.

◆ is_seq()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_seq ( ) const
inlineinherited

Forward to Tree::is_seq().

Node must be readable.

Definition at line 228 of file node.hpp.

◆ has_val()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::has_val ( ) const
inlineinherited

Forward to Tree::has_val().

Node must be readable.

Definition at line 229 of file node.hpp.

◆ has_key()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::has_key ( ) const
inlineinherited

Forward to Tree::has_key().

Node must be readable.

Definition at line 230 of file node.hpp.

◆ is_val()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_val ( ) const
inlineinherited

Forward to Tree::is_val().

Node must be readable.

Definition at line 231 of file node.hpp.

◆ is_keyval()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_keyval ( ) const
inlineinherited

Forward to Tree::is_keyval().

Node must be readable.

Definition at line 232 of file node.hpp.

◆ has_key_tag()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::has_key_tag ( ) const
inlineinherited

Forward to Tree::has_key_tag().

Node must be readable.

Definition at line 233 of file node.hpp.

◆ has_val_tag()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::has_val_tag ( ) const
inlineinherited

Forward to Tree::has_val_tag().

Node must be readable.

Definition at line 234 of file node.hpp.

◆ has_key_anchor()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::has_key_anchor ( ) const
inlineinherited

Forward to Tree::has_key_anchor().

Node must be readable.

Definition at line 235 of file node.hpp.

◆ has_val_anchor()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::has_val_anchor ( ) const
inlineinherited

Forward to Tree::has_val_anchor().

Node must be readable.

Definition at line 236 of file node.hpp.

◆ has_anchor()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::has_anchor ( ) const
inlineinherited

Forward to Tree::has_anchor().

Node must be readable.

Definition at line 237 of file node.hpp.

◆ is_key_ref()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_key_ref ( ) const
inlineinherited

Forward to Tree::is_key_ref().

Node must be readable.

Definition at line 238 of file node.hpp.

◆ is_val_ref()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_val_ref ( ) const
inlineinherited

Forward to Tree::is_val_ref().

Node must be readable.

Definition at line 239 of file node.hpp.

◆ is_ref()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_ref ( ) const
inlineinherited

Forward to Tree::is_ref().

Node must be readable.

Definition at line 240 of file node.hpp.

◆ parent_is_seq()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::parent_is_seq ( ) const
inlineinherited

Forward to Tree::parent_is_seq().

Node must be readable.

Definition at line 241 of file node.hpp.

◆ parent_is_map()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::parent_is_map ( ) const
inlineinherited

Forward to Tree::parent_is_map().

Node must be readable.

Definition at line 242 of file node.hpp.

◆ is_key_anchor()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_key_anchor ( ) const
inlinenoexceptinherited

Definition at line 244 of file node.hpp.

a CRTP base providing read-only methods for ConstNodeRef and NodeRef
Definition node.hpp:178
bool has_key_anchor() const RYML_NOEXCEPT
Forward to Tree::has_key_anchor().
Definition node.hpp:235

◆ is_val_hanchor()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_val_hanchor ( ) const
inlinenoexceptinherited

Definition at line 245 of file node.hpp.

bool has_val_anchor() const RYML_NOEXCEPT
Forward to Tree::has_val_anchor().
Definition node.hpp:236

◆ is_anchor()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_anchor ( ) const
inlinenoexceptinherited

Definition at line 246 of file node.hpp.

246{ assert_readable__(); return tree_->has_anchor(id_); }
bool has_anchor() const RYML_NOEXCEPT
Forward to Tree::has_anchor().
Definition node.hpp:237

◆ is_anchor_or_ref()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_anchor_or_ref ( ) const
inlinenoexceptinherited

Definition at line 247 of file node.hpp.

bool is_anchor_or_ref() const noexcept
Definition node.hpp:247

◆ type_has_any()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::type_has_any ( NodeType_e bits) const
inlineinherited

Forward to Tree::type_has_any().

Node must be readable.

Definition at line 258 of file node.hpp.

◆ type_has_all()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::type_has_all ( NodeType_e bits) const
inlineinherited

Forward to Tree::type_has_all().

Node must be readable.

Definition at line 259 of file node.hpp.

◆ type_has_none()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::type_has_none ( NodeType_e bits) const
inlineinherited

Forward to Tree::type_has_none().

Node must be readable.

Definition at line 260 of file node.hpp.

◆ key_style()

NodeType c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::key_style ( ) const
inlineinherited

Forward to Tree::key_style().

Node must be readable.

Definition at line 262 of file node.hpp.

◆ val_style()

NodeType c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::val_style ( ) const
inlineinherited

Forward to Tree::val_style().

Node must be readable.

Definition at line 263 of file node.hpp.

◆ is_container_styled()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_container_styled ( ) const
inlineinherited

Forward to Tree::is_container_styled().

Node must be readable.

Definition at line 265 of file node.hpp.

◆ is_block()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_block ( ) const
inlineinherited

Forward to Tree::is_block().

Node must be readable.

Definition at line 266 of file node.hpp.

◆ is_flow()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_flow ( ) const
inlineinherited

Forward to Tree::is_flow().

Node must be readable.

Definition at line 267 of file node.hpp.

◆ is_flow_sl()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_flow_sl ( ) const
inlineinherited

Forward to Tree::is_flow_sl().

Node must be readable.

Definition at line 268 of file node.hpp.

◆ is_flow_ml()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_flow_ml ( ) const
inlineinherited

Forward to Tree::is_flow_ml1().

Node must be readable.

Definition at line 270 of file node.hpp.

◆ is_flow_ml1()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_flow_ml1 ( ) const
inlineinherited

Forward to Tree::is_flow_ml1().

Node must be readable.

Definition at line 271 of file node.hpp.

◆ is_flow_mln()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_flow_mln ( ) const
inlineinherited

Forward to Tree::is_flow_mln().

Node must be readable.

Definition at line 272 of file node.hpp.

◆ is_flow_mlx()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_flow_mlx ( ) const
inlineinherited

Forward to Tree::is_flow_mlx().

Node must be readable.

Definition at line 273 of file node.hpp.

◆ has_flow_space()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::has_flow_space ( ) const
inlineinherited

Forward to Tree::has_flow_space().

Node must be readable.

Definition at line 274 of file node.hpp.

◆ is_key_styled()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_key_styled ( ) const
inlineinherited

Forward to Tree::is_key_styled().

Node must be readable.

Definition at line 276 of file node.hpp.

◆ is_val_styled()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_val_styled ( ) const
inlineinherited

Forward to Tree::is_val_styled().

Node must be readable.

Definition at line 277 of file node.hpp.

◆ is_key_literal()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_key_literal ( ) const
inlineinherited

Forward to Tree::is_key_literal().

Node must be readable.

Definition at line 278 of file node.hpp.

◆ is_val_literal()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_val_literal ( ) const
inlineinherited

Forward to Tree::is_val_literal().

Node must be readable.

Definition at line 279 of file node.hpp.

◆ is_key_folded()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_key_folded ( ) const
inlineinherited

Forward to Tree::is_key_folded().

Node must be readable.

Definition at line 280 of file node.hpp.

◆ is_val_folded()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_val_folded ( ) const
inlineinherited

Forward to Tree::is_val_folded().

Node must be readable.

Definition at line 281 of file node.hpp.

◆ is_key_squo()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_key_squo ( ) const
inlineinherited

Forward to Tree::is_key_squo().

Node must be readable.

Definition at line 282 of file node.hpp.

◆ is_val_squo()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_val_squo ( ) const
inlineinherited

Forward to Tree::is_val_squo().

Node must be readable.

Definition at line 283 of file node.hpp.

◆ is_key_dquo()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_key_dquo ( ) const
inlineinherited

Forward to Tree::is_key_dquo().

Node must be readable.

Definition at line 284 of file node.hpp.

◆ is_val_dquo()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_val_dquo ( ) const
inlineinherited

Forward to Tree::is_val_dquo().

Node must be readable.

Definition at line 285 of file node.hpp.

◆ is_key_plain()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_key_plain ( ) const
inlineinherited

Forward to Tree::is_key_plain().

Node must be readable.

Definition at line 286 of file node.hpp.

◆ is_val_plain()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_val_plain ( ) const
inlineinherited

Forward to Tree::is_val_plain().

Node must be readable.

Definition at line 287 of file node.hpp.

◆ is_key_quoted()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_key_quoted ( ) const
inlineinherited

Forward to Tree::is_key_quoted().

Node must be readable.

Definition at line 288 of file node.hpp.

◆ is_val_quoted()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_val_quoted ( ) const
inlineinherited

Forward to Tree::is_val_quoted().

Node must be readable.

Definition at line 289 of file node.hpp.

◆ is_quoted()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_quoted ( ) const
inlineinherited

Forward to Tree::is_quoted().

Node must be readable.

Definition at line 290 of file node.hpp.

◆ is_root()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_root ( ) const
inlineinherited

Forward to Tree::is_root().

Node must be readable.

Definition at line 301 of file node.hpp.

◆ has_parent()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::has_parent ( ) const
inlineinherited

Forward to Tree::has_parent() Node must be readable.

Definition at line 302 of file node.hpp.

◆ is_ancestor()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::is_ancestor ( ConstNodeRef const & ancestor) const
inlineinherited

Forward to Tree::is_ancestor() Node must be readable.

Definition at line 303 of file node.hpp.

◆ has_child()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::has_child ( ConstNodeRef const & n) const
inlineinherited

Forward to Tree::has_child().

Node must be readable.

Definition at line 305 of file node.hpp.

◆ has_children()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::has_children ( ) const
inlineinherited

Forward to Tree::has_children().

Node must be readable.

Definition at line 308 of file node.hpp.

◆ has_sibling()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::has_sibling ( ConstNodeRef const & n) const
inlineinherited

Forward to Tree::has_sibling().

Node must be readable.

Definition at line 310 of file node.hpp.

◆ has_other_siblings()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::has_other_siblings ( ) const
inlineinherited

Forward to Tree::has_other_siblings().

Node must be readable.

Definition at line 313 of file node.hpp.

◆ has_siblings()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::has_siblings ( ) const
inlineinherited

Definition at line 315 of file node.hpp.

bool has_siblings() const RYML_NOEXCEPT
Definition node.hpp:315

◆ num_children()

id_type c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::num_children ( ) const
inlineinherited

O(num_children).

Forward to Tree::num_children().

Definition at line 326 of file node.hpp.

◆ num_siblings()

id_type c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::num_siblings ( ) const
inlineinherited

O(num_children).

Forward to Tree::num_siblings().

Definition at line 327 of file node.hpp.

◆ num_other_siblings()

id_type c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::num_other_siblings ( ) const
inlineinherited

O(num_siblings).

Forward to Tree::num_other_siblings().

Definition at line 328 of file node.hpp.

◆ child_pos()

id_type c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::child_pos ( ConstNodeRef const & n) const
inlineinherited

O(num_children).

Forward to Tree::child_pos().

Definition at line 329 of file node.hpp.

◆ sibling_pos()

id_type c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::sibling_pos ( ConstNodeRef const & n) const
inlineinherited

O(num_siblings).

Forward to Tree::sibling_pos().

Definition at line 330 of file node.hpp.

◆ depth_asc()

id_type c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::depth_asc ( ) const
inlineinherited

Definition at line 332 of file node.hpp.

332{ assert_readable__(); return tree_->depth_asc(id_); } /** O(log(num_nodes)). Forward to Tree::depth_asc(). Node must be readable. */
id_type depth_asc() const RYML_NOEXCEPT
Definition node.hpp:332

◆ depth_desc()

id_type c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::depth_desc ( ) const
inlineinherited

O(log(num_nodes)).

Forward to Tree::depth_asc(). Node must be readable.

Definition at line 333 of file node.hpp.

333{ assert_readable__(); return tree_->depth_desc(id_); } /** O(num_nodes). Forward to Tree::depth_desc(). Node must be readable. */
id_type depth_desc() const RYML_NOEXCEPT
O(log(num_nodes)).
Definition node.hpp:333

◆ location()

Location c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::location ( Parser const & parser) const
inlineinherited

Definition at line 342 of file node.hpp.

343 {
345 return tree_->location(parser, id_);
346 }
Location location(Parser const &parser) const
Definition node.hpp:342

◆ operator>>()

ConstNodeRef const & c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::operator>> ( T & v) const
inlineinherited

deserialize the node's val to the given variable, forwarding to the user-overrideable read() function.

Definition at line 358 of file node.hpp.

359 {
361 if( ! read((ConstImpl const&)*this, &v))
362 _RYML_ERR_VISIT_(tree_->m_callbacks, tree_, id_, "could not deserialize value");
363 return *((ConstImpl const*)this);
364 }
bool read(ConstNodeRef const &n, T *v)
Definition node.hpp:1739

◆ get_if()

bool c4::yml::detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >::get_if ( csubstr name,
T * var ) const
inlineinherited

look for a child by name, if it exists assign to var.

return true if the child existed.

Definition at line 389 of file node.hpp.

390 {
392 ConstImpl ch = ((ConstImpl const*)this)->find_child(name);
393 if(!ch.readable())
394 return false;
395 ch >> *var;
396 return true;
397 }

◆ detail::RoNodeMethods< ConstNodeRef, ConstNodeRef >

Definition at line 488 of file node.hpp.

Member Data Documentation

◆ m_tree

Tree const* c4::yml::ConstNodeRef::m_tree

Definition at line 485 of file node.hpp.

◆ m_id

id_type c4::yml::ConstNodeRef::m_id

Definition at line 486 of file node.hpp.

◆ NodeRef

friend c4::yml::ConstNodeRef::NodeRef

Definition at line 488 of file node.hpp.


The documentation for this class was generated from the following file:
  • /home/docs/checkouts/readthedocs.org/user_builds/rapidyaml/checkouts/latest/src/c4/yml/node.hpp