22xsltNewNsAlias(xsltCompilerCtxtPtr cctxt)
32 "Internal error in xsltNewNsAlias(): Memory allocation failed.\n");
33 cctxt->style->errors++;
40 ret->next = cctxt->nsAliases;
41 cctxt->nsAliases =
ret;
91 if (stylePrefix ==
NULL) {
93 "The attribute 'stylesheet-prefix' is missing.\n");
100 if (literalNs ==
NULL) {
102 "Attribute 'stylesheet-prefix': There's no namespace "
103 "declaration in scope for the prefix '%s'.\n",
112 if (resultPrefix ==
NULL) {
114 "The attribute 'result-prefix' is missing.\n");
122 if (targetNs ==
NULL) {
124 "Attribute 'result-prefix': There's no namespace "
125 "declaration in scope for the prefix '%s'.\n",
170 alias->literalNs = literalNs;
171 alias->targetNs = targetNs;
172 XSLT_CCTXT(
style)->hasNsAliases = 1;
184 if (stylePrefix ==
NULL) {
186 "namespace-alias: stylesheet-prefix attribute missing\n");
190 if (resultPrefix ==
NULL) {
192 "namespace-alias: result-prefix attribute missing\n");
198 if (literalNs ==
NULL) {
199 literalNsName =
NULL;
201 literalNsName = literalNs->
href;
207 "namespace-alias: prefix %s not bound to any namespace\n",
211 literalNsName = literalNs->
href;
221 if (targetNs ==
NULL) {
224 targetNsName = targetNs->
href;
230 "namespace-alias: prefix %s not bound to any namespace\n",
234 targetNsName = targetNs->
href;
241 if (literalNsName ==
NULL) {
242 if (targetNs !=
NULL) {
261 "namespace-alias: cannot create hash table\n");
265 literalNsName, (
void *) targetNsName);
270 if (stylePrefix !=
NULL)
272 if (resultPrefix !=
NULL)
304 int prefixOccupied = 0;
324 if ((nsPrefix ==
NULL) && ((nsName ==
NULL) || (nsName[0] == 0))) {
342 if ((
ns->href !=
NULL) && (
ns->href[0] != 0)) {
347 "Namespace normalization error: Cannot undeclare "
348 "the default namespace, since the default namespace "
349 "'%s' is already declared on the result element "
396 if ((nsPrefix !=
NULL) &&
397 (nsPrefix[0] ==
'x') && (nsPrefix[1] ==
'm') &&
398 (nsPrefix[2] ==
'l') && (nsPrefix[3] == 0))
424 if (prefixOccupied) {
456 if (nsPrefix ==
NULL) {
497 goto declare_new_prefix;
549 if (nsPrefix ==
NULL) {
558 "Internal error in xsltAcquireResultInScopeNs(): "
559 "Failed to compute a unique ns-prefix for the "
560 "generated element");
603#ifdef XSLT_REFACTORED
646 }
else if (URI ==
NULL)
734#ifdef XSLT_REFACTORED
GLdouble GLdouble GLdouble GLdouble q
xsltStylesheetPtr xsltNextImport(xsltStylesheetPtr cur)
xmlNsPtr xsltCopyNamespace(xsltTransformContextPtr ctxt ATTRIBUTE_UNUSED, xmlNodePtr elem, xmlNsPtr ns)
void xsltFreeNamespaceAliasHashes(xsltStylesheetPtr style)
xmlNsPtr xsltGetPlainNamespace(xsltTransformContextPtr ctxt, xmlNodePtr cur, xmlNsPtr ns, xmlNodePtr out)
void xsltNamespaceAlias(xsltStylesheetPtr style, xmlNodePtr node)
xmlNsPtr xsltGetSpecialNamespace(xsltTransformContextPtr ctxt, xmlNodePtr invocNode, const xmlChar *nsName, const xmlChar *nsPrefix, xmlNodePtr target)
xmlNsPtr xsltCopyNamespaceList(xsltTransformContextPtr ctxt, xmlNodePtr node, xmlNsPtr cur)
xmlNsPtr xsltGetNamespace(xsltTransformContextPtr ctxt, xmlNodePtr cur, xmlNsPtr ns, xmlNodePtr out)
#define UNDEFINED_DEFAULT_NS
XMLPUBVAR xmlMallocFunc xmlMalloc
XMLPUBVAR xmlFreeFunc xmlFree
XMLPUBFUN void XMLCALL xmlHashFree(xmlHashTablePtr table, xmlHashDeallocator f)
XMLPUBFUN void *XMLCALL xmlHashLookup(xmlHashTablePtr table, const xmlChar *name)
XMLPUBFUN xmlHashTablePtr XMLCALL xmlHashCreate(int size)
XMLPUBFUN int XMLCALL xmlHashAddEntry(xmlHashTablePtr table, const xmlChar *name, void *userdata)
XMLPUBFUN xmlNsPtr XMLCALL xmlSearchNs(xmlDocPtr doc, xmlNodePtr node, const xmlChar *nameSpace)
XMLPUBFUN xmlChar *XMLCALL xmlGetNsProp(const xmlNode *node, const xmlChar *name, const xmlChar *nameSpace)
XMLPUBFUN xmlNsPtr XMLCALL xmlSearchNsByHref(xmlDocPtr doc, xmlNodePtr node, const xmlChar *href)
XMLPUBFUN xmlNsPtr XMLCALL xmlNewNs(xmlNodePtr node, const xmlChar *href, const xmlChar *prefix)
xmlHashTablePtr nsAliases
XMLPUBFUN int XMLCALL xmlStrEqual(const xmlChar *str1, const xmlChar *str2)
void xsltTransformError(xsltTransformContextPtr ctxt, xsltStylesheetPtr style, xmlNodePtr node, const char *msg,...)