MCPcopy Create free account
hub / github.com/deeptir18/cornflakes / first_node

Method first_node

include/cereal/external/rapidxml/rapidxml.hpp:949–962  ·  view source on GitHub ↗

Gets first child node, optionally matching node name. \param name_ Name of child to find, or 0 to return first child regardless of its name; this string doesn't have to be zero-terminated if name_size is non-zero \param name_size_ Size of name, in characters, or 0 to have size calculated automatically from string \param case_sensitive Should name comparison be case-sensitive; non case-sensitive co

Source from the content-addressed store, hash-verified

947 //! \param case_sensitive Should name comparison be case-sensitive; non case-sensitive comparison works properly only for ASCII characters
948 //! \return Pointer to found child, or 0 if not found.
949 xml_node<Ch> *first_node(const Ch *name_ = 0, std::size_t name_size_ = 0, bool case_sensitive = true) const
950 {
951 if (name_)
952 {
953 if (name_size_ == 0)
954 name_size_ = internal::measure(name_);
955 for (xml_node<Ch> *child = m_first_node; child; child = child->next_sibling())
956 if (internal::compare(child->name(), child->name_size(), name_, name_size_, case_sensitive))
957 return child;
958 return 0;
959 }
960 else
961 return m_first_node;
962 }
963
964 //! Gets last child node, optionally matching node name.
965 //! Behaviour is undefined if node has no children.

Callers 9

XMLInputArchiveMethod · 0.80
getNumChildrenMethod · 0.80
NodeInfoMethod · 0.80
searchMethod · 0.80
count_childrenFunction · 0.80
node_iteratorMethod · 0.80
clone_nodeMethod · 0.80
print_childrenFunction · 0.80
print_element_nodeFunction · 0.80

Calls 5

measureFunction · 0.85
compareFunction · 0.85
next_siblingMethod · 0.80
name_sizeMethod · 0.80
nameMethod · 0.45

Tested by

no test coverage detected