Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ MergeNamespaces()

static NsDecl System.Xml.Xsl.Xslt.XsltLoader.MergeNamespaces ( NsDecl thisList,
NsDecl parentList )
inlinestaticprivate

Definition at line 2355 of file XsltLoader.cs.

2356 {
2357 if (parentList == null)
2358 {
2359 return thisList;
2360 }
2361 if (thisList == null)
2362 {
2363 return parentList;
2364 }
2365 while (parentList != null)
2366 {
2367 bool flag = false;
2368 for (NsDecl nsDecl = thisList; nsDecl != null; nsDecl = nsDecl.Prev)
2369 {
2370 if (Ref.Equal(nsDecl.Prefix, parentList.Prefix) && (nsDecl.Prefix != null || nsDecl.NsUri == parentList.NsUri))
2371 {
2372 flag = true;
2373 break;
2374 }
2375 }
2376 if (!flag)
2377 {
2378 thisList = new NsDecl(thisList, parentList.Prefix, parentList.NsUri);
2379 }
2380 parentList = parentList.Prev;
2381 }
2382 return thisList;
2383 }

References System.Xml.Dictionary, and System.Xml.Ref.Equal().

Referenced by System.Xml.Xsl.Xslt.XsltLoader.LoadAttributeSet(), System.Xml.Xsl.Xslt.XsltLoader.LoadDecimalFormat(), System.Xml.Xsl.Xslt.XsltLoader.LoadGlobalVariableOrParameter(), System.Xml.Xsl.Xslt.XsltLoader.LoadKey(), System.Xml.Xsl.Xslt.XsltLoader.LoadMsScript(), System.Xml.Xsl.Xslt.XsltLoader.LoadNamespaceAlias(), System.Xml.Xsl.Xslt.XsltLoader.LoadPreserveSpace(), System.Xml.Xsl.Xslt.XsltLoader.LoadStripSpace(), and System.Xml.Xsl.Xslt.XsltLoader.LoadTemplate().