System.Xml.Xsl.Runtime.XmlExtensionFunction.GetXmlArgumentType C# (CSharp) Method

GetXmlArgumentType() public method

Once Bind has been successfully called, the inferred Xml types of the arguments can be accessed.
public GetXmlArgumentType ( int index ) : XmlQueryType
index int
return XmlQueryType
        public XmlQueryType GetXmlArgumentType(int index) {
            return this.argXmlTypes[index];
        }

Usage Example

Exemplo n.º 1
0
        public XmlQueryType CheckXsltInvokeEarlyBound(QilInvokeEarlyBound node) {
        #if DEBUG
            CheckLiteralValue(node[0], typeof(QilName));
            CheckLiteralValue(node[1], typeof(MethodInfo));
            CheckClassAndNodeType(node[2], typeof(QilList), QilNodeType.ActualParameterList);

            XmlExtensionFunction extFunc = new XmlExtensionFunction(node.Name.LocalName, node.Name.NamespaceUri, node.ClrMethod);
            QilList actualArgs = node.Arguments;
            Check(actualArgs.Count == extFunc.Method.GetParameters().Length, actualArgs, "InvokeEarlyBound argument count must match function's argument count");

            for (int i = 0; i < actualArgs.Count; i++) {
                Check(actualArgs[i].XmlType.IsSubtypeOf(extFunc.GetXmlArgumentType(i)), actualArgs[i], "InvokeEarlyBound argument must be a subtype of the invoked function's argument type");
            }
        #endif

            return node.XmlType;
        }
All Usage Examples Of System.Xml.Xsl.Runtime.XmlExtensionFunction::GetXmlArgumentType