MCPcopy Create free account
hub / github.com/axmolengine/axmol / step_push

Method step_push

3rdparty/pugixml/pugixml.cpp:10029–10067  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

10027 }
10028
10029 bool step_push(xpath_node_set_raw& ns, xml_attribute_struct* a, xml_node_struct* parent, xpath_allocator* alloc)
10030 {
10031 assert(a);
10032
10033 const char_t* name = a->name ? a->name + 0 : PUGIXML_TEXT("");
10034
10035 switch (_test)
10036 {
10037 case nodetest_name:
10038 if (strequal(name, _data.nodetest) && is_xpath_attribute(name))
10039 {
10040 ns.push_back(xpath_node(xml_attribute(a), xml_node(parent)), alloc);
10041 return true;
10042 }
10043 break;
10044
10045 case nodetest_type_node:
10046 case nodetest_all:
10047 if (is_xpath_attribute(name))
10048 {
10049 ns.push_back(xpath_node(xml_attribute(a), xml_node(parent)), alloc);
10050 return true;
10051 }
10052 break;
10053
10054 case nodetest_all_in_namespace:
10055 if (starts_with(name, _data.nodetest) && is_xpath_attribute(name))
10056 {
10057 ns.push_back(xpath_node(xml_attribute(a), xml_node(parent)), alloc);
10058 return true;
10059 }
10060 break;
10061
10062 default:
10063 ;
10064 }
10065
10066 return false;
10067 }
10068
10069 bool step_push(xpath_node_set_raw& ns, xml_node_struct* n, xpath_allocator* alloc)
10070 {

Callers

nothing calls this directly

Calls 6

strequalFunction · 0.85
is_xpath_attributeFunction · 0.85
xpath_nodeClass · 0.85
xml_nodeClass · 0.85
starts_withFunction · 0.70
push_backMethod · 0.45

Tested by

no test coverage detected