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

◆ InsertExNamespaces()

void System.Xml.Xsl.Xslt.XsltInput.InsertExNamespaces ( int attExPrefixes,
ContextInfo ctxInfo,
bool extensions )
inlineprivate

Definition at line 957 of file XsltInput.cs.

958 {
960 {
961 return;
962 }
963 string value = Value;
964 if (value.Length == 0)
965 {
966 return;
967 }
968 if (!extensions && _compiler.Version != 1 && value == "#all")
969 {
970 ctxInfo.nsList = new NsDecl(ctxInfo.nsList, null, null);
971 return;
972 }
974 string[] array = XmlConvert.SplitString(value);
975 for (int i = 0; i < array.Length; i++)
976 {
977 if (array[i] == "#default")
978 {
979 array[i] = LookupXmlNamespace(string.Empty);
980 if (array[i].Length == 0 && _compiler.Version != 1 && !BackwardCompatibility)
981 {
983 }
984 }
985 else
986 {
988 }
989 }
991 {
992 return;
993 }
994 for (int j = 0; j < array.Length; j++)
995 {
996 if (array[j] != null)
997 {
998 ctxInfo.nsList = new NsDecl(ctxInfo.nsList, null, array[j]);
999 if (extensions)
1000 {
1001 _scopeManager.AddExNamespace(array[j]);
1002 }
1003 }
1004 }
1005 }
static string Xslt_ExcludeDefault
Definition SR.cs:2008
Definition SR.cs:7
bool ExitForwardsCompatible(bool fwdCompat)
Definition Compiler.cs:315
readonly CompilerScopeManager< VarPar > _scopeManager
Definition XsltInput.cs:146
string LookupXmlNamespace(string prefix)
void ReportError(string res, params string[] args)
readonly Compiler _compiler
Definition XsltInput.cs:150
bool MoveToLiteralAttribute(int attNum)
Definition XsltInput.cs:670

References System.Xml.Xsl.Xslt.XsltInput._compiler, System.Xml.Xsl.Xslt.XsltInput._scopeManager, System.array, System.Xml.Xsl.Xslt.XsltInput.BackwardCompatibility, System.Xml.Dictionary, System.Xml.Xsl.Xslt.Compiler.EnterForwardsCompatible(), System.Xml.Xsl.Xslt.Compiler.ExitForwardsCompatible(), System.Xml.Xsl.Xslt.XsltInput.ForwardCompatibility, System.Xml.Xsl.Xslt.XsltInput.LookupXmlNamespace(), System.Xml.Xsl.Xslt.XsltInput.MoveToLiteralAttribute(), System.Xml.Xsl.Xslt.XsltInput.ReportError(), System.Xml.XmlConvert.SplitString(), System.value, System.Xml.Xsl.Xslt.XsltInput.Value, System.Xml.Xsl.Xslt.Compiler.Version, and System.SR.Xslt_ExcludeDefault.

Referenced by System.Xml.Xsl.Xslt.XsltInput.GetAttributes(), and System.Xml.Xsl.Xslt.XsltInput.GetLiteralAttributes().