Lines Matching refs:prefix
97 static xmlNsPtr dom_create_owned_ns(zend_string *prefix, zend_string *uri) in dom_create_owned_ns() argument
99 ZEND_ASSERT(prefix != NULL); in dom_create_owned_ns()
106 ns->prefix = ZSTR_LEN(prefix) == 0 ? NULL : BAD_CAST ZSTR_VAL(prefix); in dom_create_owned_ns()
114 …om_libxml_ns_mapper_get_ns(php_dom_libxml_ns_mapper *mapper, zend_string *prefix, zend_string *uri) in php_dom_libxml_ns_mapper_get_ns() argument
120 if (prefix == NULL) { in php_dom_libxml_ns_mapper_get_ns()
121 prefix = zend_empty_string; in php_dom_libxml_ns_mapper_get_ns()
124 if (ZSTR_LEN(prefix) == 0 && ZSTR_LEN(uri) == 0) { in php_dom_libxml_ns_mapper_get_ns()
129 xmlNsPtr found = zend_hash_find_ptr(prefix_map, prefix); in php_dom_libxml_ns_mapper_get_ns()
134 xmlNsPtr ns = dom_create_owned_ns(prefix, uri); in php_dom_libxml_ns_mapper_get_ns()
138 zend_hash_add_new(prefix_map, prefix, &new_zv); in php_dom_libxml_ns_mapper_get_ns()
143 …et_ns_raw_prefix_string(php_dom_libxml_ns_mapper *mapper, const xmlChar *prefix, size_t prefix_len… in php_dom_libxml_ns_mapper_get_ns_raw_prefix_string() argument
150 zend_string *prefix_str = zend_string_init((const char *) prefix, prefix_len, false); in php_dom_libxml_ns_mapper_get_ns_raw_prefix_string()
157 …pper_get_ns_raw_strings_ex(php_dom_libxml_ns_mapper *mapper, const char *prefix, size_t prefix_len… in php_dom_libxml_ns_mapper_get_ns_raw_strings_ex() argument
159 zend_string *prefix_str = zend_string_init(prefix, prefix_len, false); in php_dom_libxml_ns_mapper_get_ns_raw_strings_ex()
167 …ns_mapper_get_ns_raw_strings(php_dom_libxml_ns_mapper *mapper, const char *prefix, const char *uri) in php_dom_libxml_ns_mapper_get_ns_raw_strings() argument
169 …return php_dom_libxml_ns_mapper_get_ns_raw_strings_ex(mapper, prefix, strlen(prefix), uri, strlen(… in php_dom_libxml_ns_mapper_get_ns_raw_strings()
172 …_get_ns_raw_strings_nullsafe(php_dom_libxml_ns_mapper *mapper, const char *prefix, const char *uri) in php_dom_libxml_ns_mapper_get_ns_raw_strings_nullsafe() argument
174 if (prefix == NULL) { in php_dom_libxml_ns_mapper_get_ns_raw_strings_nullsafe()
175 prefix = ""; in php_dom_libxml_ns_mapper_get_ns_raw_strings_nullsafe()
180 return php_dom_libxml_ns_mapper_get_ns_raw_strings(mapper, prefix, uri); in php_dom_libxml_ns_mapper_get_ns_raw_strings_nullsafe()
192 const char *prefix = (const char *) ns->prefix; in php_dom_libxml_ns_mapper_store_and_normalize_parsed_ns() local
194 if (prefix == NULL) { in php_dom_libxml_ns_mapper_store_and_normalize_parsed_ns()
195 prefix = ""; in php_dom_libxml_ns_mapper_store_and_normalize_parsed_ns()
198 prefix_len = xmlStrlen(ns->prefix); in php_dom_libxml_ns_mapper_store_and_normalize_parsed_ns()
201 zval *zv = zend_hash_str_find_ptr(prefix_map, prefix, prefix_len); in php_dom_libxml_ns_mapper_store_and_normalize_parsed_ns()
208 zend_hash_str_add_new(prefix_map, prefix, prefix_len, &new_zv); in php_dom_libxml_ns_mapper_store_and_normalize_parsed_ns()
231 if (ns->prefix != NULL) { in php_dom_ns_compat_mark_attribute()
233 name = ns->prefix; in php_dom_ns_compat_mark_attribute()
325 xmlNsPtr matching_ns = xmlSearchNs(nodep->doc, nodep, attrp->ns->prefix); in php_dom_reconcile_attribute_namespace_after_insertion()
330 if (attrp->ns->prefix != NULL) { in php_dom_reconcile_attribute_namespace_after_insertion()
352 const char *prefix = (const char *) node->ns->prefix; in php_dom_libxml_reconcile_modern_single_node() local
354 new_ns = php_dom_libxml_ns_mapper_get_ns_raw_strings_nullsafe(ctx->ns_mapper, prefix, href); in php_dom_libxml_reconcile_modern_single_node()
394 …s_mapper_get_ns_raw_strings_nullsafe(ns_mapper, (const char *) node->ns->prefix, (const char *) no… in php_dom_libxml_reconcile_modern()
443 if (!ignore_elements && cur->ns != NULL && cur->ns->prefix != NULL) { in php_dom_get_in_scope_ns()
444 const char *prefix = (const char *) cur->ns->prefix; in php_dom_get_in_scope_ns() local
445 zend_hash_str_add_ptr(&tmp_prefix_to_ns_table, prefix, strlen(prefix), cur->ns); in php_dom_get_in_scope_ns()
450 …if (attr->ns != NULL && attr->ns->prefix != NULL && php_dom_ns_is_fast_ex(attr->ns, php_dom_ns_is_… in php_dom_get_in_scope_ns()
454 const char *prefix = (const char *) attr->name; in php_dom_get_in_scope_ns() local
455 …xmlNsPtr ns = php_dom_libxml_ns_mapper_get_ns_raw_strings(ns_mapper, prefix, (const char *) attr->… in php_dom_get_in_scope_ns()
456 zend_hash_str_add_ptr(&tmp_prefix_to_ns_table, prefix, strlen(prefix), ns); in php_dom_get_in_scope_ns()