Gets next attribute, optionally matching attribute name. \param name Name of attribute to find, or 0 to return next attribute 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-sens
| 854 | //! \param case_sensitive Should name comparison be case-sensitive; non case-sensitive comparison works properly only for ASCII characters |
| 855 | //! \return Pointer to found attribute, or 0 if not found. |
| 856 | xml_attribute<Ch> *next_attribute(const Ch *name = 0, std::size_t name_size = 0, bool case_sensitive = true) const |
| 857 | { |
| 858 | if (name) |
| 859 | { |
| 860 | if (name_size == 0) |
| 861 | name_size = internal::measure(name); |
| 862 | for (xml_attribute<Ch> *attribute = m_next_attribute; attribute; attribute = attribute->m_next_attribute) |
| 863 | if (internal::compare(attribute->name(), attribute->name_size(), name, name_size, case_sensitive)) |
| 864 | return attribute; |
| 865 | return 0; |
| 866 | } |
| 867 | else |
| 868 | return this->m_parent ? m_next_attribute : 0; |
| 869 | } |
| 870 | |
| 871 | private: |
| 872 |
no test coverage detected