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

◆ GetDataSource()

XPathNavigator System.Xml.Xsl.Runtime.XmlQueryContext.GetDataSource ( string uriRelative,
string uriBase )
inline

Definition at line 86 of file XmlQueryContext.cs.

87 {
89 try
90 {
91 Uri baseUri = ((uriBase != null) ? _dataSources.ResolveUri(null, uriBase) : null);
92 Uri uri = _dataSources.ResolveUri(baseUri, uriRelative);
93 if (uri != null)
94 {
96 }
97 if (xPathNavigator == null)
98 {
99 object entity = _dataSources.GetEntity(uri, null, null);
100 if (entity != null)
101 {
104 }
105 }
106 }
107 catch (XslTransformException)
108 {
109 throw;
110 }
111 catch (Exception ex2)
112 {
113 if (!XmlException.IsCatchableException(ex2))
114 {
115 throw;
116 }
117 throw new XslTransformException(ex2, System.SR.XmlIl_DocumentLoadError, uriRelative);
118 }
119 return xPathNavigator;
120 }
virtual void Add(object key, object? value)
Definition Hashtable.cs:676
static string XmlIl_DocumentLoadError
Definition SR.cs:2064
Definition SR.cs:7
object? GetEntity(Uri absoluteUri, string? role, Type? ofObjectToReturn)
virtual Uri ResolveUri(Uri? baseUri, string? relativeUri)
XPathNavigator ConstructDocument(object dataSource, string uriRelative, Uri uriResolved)

References System.Xml.Xsl.Runtime.XmlQueryContext._dataSourceCache, System.Xml.Xsl.Runtime.XmlQueryContext._dataSources, System.Collections.Hashtable.Add(), System.Xml.Xsl.Runtime.XmlQueryContext.ConstructDocument(), System.Xml.Dictionary, System.Xml.XmlResolver.GetEntity(), System.Xml.XmlException.IsCatchableException(), System.Xml.XmlResolver.ResolveUri(), and System.SR.XmlIl_DocumentLoadError.

Referenced by System.Xml.Xsl.Runtime.XmlQueryContext.XmlQueryContext().