C# Class System.Xml.Xsl.Runtime.XmlQueryContext

Mostrar archivo Open project: gbarnett/shared-source-cli-2.0 Class Usage Examples

Public Methods

Method Description
GetDataSource ( string uriRelative, string uriBase ) : XPathNavigator

Fetch the data source specified by "uriRelative" and "uriBase" from the XmlResolver that the user provided. If the resolver returns a stream or reader, create an instance of XPathDocument. If the resolver returns an XPathNavigator, return the navigator. Throw an exception if no data source was found.

GetLateBoundObject ( string namespaceUri ) : object

Return the extension object that is mapped to the specified namespace, or null if no object is mapped.

GetParameter ( string localName, string namespaceUri ) : object

Get a named parameter from the external argument list. Return null if no argument list was provided, or if there is no parameter by that name.

InvokeXsltLateBoundFunction ( string name, string namespaceUri, IList args ) : IList

Get a late-bound extension object from the external argument list. Bind to a method on the object and invoke it, passing "args" as arguments.

LateBoundFunctionExists ( string name, string namespaceUri ) : bool

Return true if the late bound object identified by "namespaceUri" contains a method that matches "name".

Private Methods

Method Description
ConstructDocument ( object dataSource, string uriRelative, Uri uriResolved ) : XPathNavigator

Ensure that "dataSource" is cached as an XPathDocument and return a navigator over the document.

XmlQueryContext ( XmlQueryRuntime runtime, object defaultDataSource, XmlResolver dataSources, XsltArgumentList argList, System.Xml.Xsl.Runtime.WhitespaceRuleLookup wsRules ) : System

This constructor is internal so that external users cannot construct it (and therefore we do not have to test it separately).

Method Details

GetDataSource() public method

Fetch the data source specified by "uriRelative" and "uriBase" from the XmlResolver that the user provided. If the resolver returns a stream or reader, create an instance of XPathDocument. If the resolver returns an XPathNavigator, return the navigator. Throw an exception if no data source was found.
public GetDataSource ( string uriRelative, string uriBase ) : XPathNavigator
uriRelative string
uriBase string
return System.Xml.XPath.XPathNavigator

GetLateBoundObject() public method

Return the extension object that is mapped to the specified namespace, or null if no object is mapped.
public GetLateBoundObject ( string namespaceUri ) : object
namespaceUri string
return object

GetParameter() public method

Get a named parameter from the external argument list. Return null if no argument list was provided, or if there is no parameter by that name.
public GetParameter ( string localName, string namespaceUri ) : object
localName string
namespaceUri string
return object

InvokeXsltLateBoundFunction() public method

Get a late-bound extension object from the external argument list. Bind to a method on the object and invoke it, passing "args" as arguments.
public InvokeXsltLateBoundFunction ( string name, string namespaceUri, IList args ) : IList
name string
namespaceUri string
args IList
return IList

LateBoundFunctionExists() public method

Return true if the late bound object identified by "namespaceUri" contains a method that matches "name".
public LateBoundFunctionExists ( string name, string namespaceUri ) : bool
name string
namespaceUri string
return bool