• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

C# XPathResultType类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了C#中XPathResultType的典型用法代码示例。如果您正苦于以下问题:C# XPathResultType类的具体用法?C# XPathResultType怎么用?C# XPathResultType使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



XPathResultType类属于命名空间,在下文中一共展示了XPathResultType类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。

示例1: XPathResult

 internal XPathResult(XPathNodeIterator nodeSetResult)
     : this()
 {
     this.nodeSetResult = nodeSetResult;
     this.internalIterator = nodeSetResult as SafeNodeSequenceIterator;
     this.resultType = XPathResultType.NodeSet;
 }
开发者ID:iskiselev,项目名称:JSIL.NetFramework,代码行数:7,代码来源:XPathResult.cs


示例2: ResolveFunction

            public override IXsltContextFunction ResolveFunction(string prefix, string name, XPathResultType[] argTypes)
            {
                if (string.IsNullOrEmpty(prefix))
                   return base.ResolveFunction(prefix, name, argTypes);

                return mvpContext.ResolveFunction(prefix, name, argTypes);
            }
开发者ID:richardschneider,项目名称:sepia,代码行数:7,代码来源:ExsltQueryLanguage.cs


示例3: SetXsltContext

 public override void SetXsltContext(XsltContext context)
 {
     if (context == null)
     {
         throw XPathException.Create(SR.Xp_NoContext);
     }
     if (this.xsltContext != context)
     {
         xsltContext = context;
         foreach (Query argument in _args)
         {
             argument.SetXsltContext(context);
         }
         XPathResultType[] argTypes = new XPathResultType[_args.Count];
         for (int i = 0; i < _args.Count; i++)
         {
             argTypes[i] = _args[i].StaticType;
         }
         _function = xsltContext.ResolveFunction(prefix, name, argTypes);
         // KB article allows to return null, see http://support.microsoft.com/?kbid=324462#6
         if (_function == null)
         {
             throw XPathException.Create(SR.Xp_UndefFunc, QName);
         }
     }
 }
开发者ID:noahfalk,项目名称:corefx,代码行数:26,代码来源:FunctionQuery.cs


示例4: CheckNodeSet

 private void CheckNodeSet(XPathResultType t)
 {
     if ((t != XPathResultType.NodeSet) && (t != XPathResultType.Any))
     {
         throw XPathException.Create("Xp_NodeSetExpected", this.scanner.SourceText);
     }
 }
开发者ID:pritesh-mandowara-sp,项目名称:DecompliedDotNetLibraries,代码行数:7,代码来源:XPathParser.cs


示例5: TriflesXPathExtensionFunction

        /// <summary>
        /// Creates a new extension function definition.
        /// </summary>
        /// <param name="name"></param>
        /// <param name="minArgs"></param>
        /// <param name="maxArgs"></param>
        /// <param name="argTypes"></param>
        /// <param name="returnType"></param>
        /// <param name="fn"></param>
        public TriflesXPathExtensionFunction(XName name, int minArgs, int maxArgs, XPathResultType[] argTypes, XPathResultType returnType, TriflesXPathInvokable fn)
        {
            FunctionName = Checker.NotNull(name, "name");

            Minargs = minArgs;
            Maxargs = maxArgs;

            if (Minargs < 0)
            {
                throw new ArgumentOutOfRangeException("minArgs");
            }
            else if (Maxargs < Minargs)
            {
                throw new ArgumentOutOfRangeException("maxArgs", "maxArgs cannot be less than minArgs");
            }

            if (argTypes == null)
            {
                argTypes = new XPathResultType[0];
            }

            this.argTypes = argTypes.ToImmutableArray();

            ReturnType = Checker.NotNull(returnType, "returnType");

            invokable = Checker.NotNull(fn, "fn");
        }
开发者ID:falldave,项目名称:falldave-trifles-net,代码行数:36,代码来源:TriflesXPathExtensionFunction.cs


示例6: ResolveFunction

 public override IXsltContextFunction ResolveFunction(string prefix, string name, XPathResultType[] argTypes)
 {
   XsltFunction function;
   if (functions.TryGetValue(name, out function))
     return function;
   return baseContext.ResolveFunction(prefix, name, argTypes);
 }
开发者ID:jogibear9988,项目名称:ormbattle,代码行数:7,代码来源:DefaultXsltContext.cs


示例7: XPathMessageFunction

 protected XPathMessageFunction(XPathResultType[] argTypes, int max, int min, XPathResultType retType)
 {
     this.argTypes = argTypes;
     this.maxArgs = max;
     this.minArgs = min;
     this.retType = retType;
 }
开发者ID:pritesh-mandowara-sp,项目名称:DecompliedDotNetLibraries,代码行数:7,代码来源:XPathMessageFunction.cs


示例8: Init

		protected void Init (int minArgs, int maxArgs, XPathResultType returnType, XPathResultType[] argTypes)
		{
			this.minargs	= minArgs;
			this.maxargs	= maxArgs;
			this.returnType = returnType;
			this.argTypes	= argTypes;
		}
开发者ID:calumjiao,项目名称:Mono-Class-Libraries,代码行数:7,代码来源:XslFunctions.cs


示例9: ExsltContextFunction

		public ExsltContextFunction(MethodInfo mi, XPathResultType[] argTypes,
			object owner)
		{
			_method = mi;
			_argTypes = argTypes;
			_ownerObj = owner;
		}
开发者ID:zanyants,项目名称:mvp.xml,代码行数:7,代码来源:ExsltContextFunction.cs


示例10: CustomXsltFunction

 public CustomXsltFunction(string name, XPathResultType[] argTypes, XPathResultType returnType, InvokedFunction function = null)
 {
     Prefix = String.Empty;
     Name = name;
     ArgTypes = argTypes;
     ReturnType = returnType;
     Function = function;
 }
开发者ID:tiloc,项目名称:fhir-net-api,代码行数:8,代码来源:CustomXsltFunction.cs


示例11: ResolveFunction

            public override IXsltContextFunction ResolveFunction(string prefix, string name, XPathResultType[] argTypes)
            {
                IXsltContextFunction function = null;
                if (string.IsNullOrEmpty(prefix))
                    functions.TryGetValue(name, out function);

                return function ?? base.ResolveFunction(prefix, name, argTypes);
            }
开发者ID:richardschneider,项目名称:sepia,代码行数:8,代码来源:Xslt2QueryLanguage.cs


示例12: ResolveFunction

 public override IXsltContextFunction ResolveFunction(string prefix, string name, XPathResultType[] ArgTypes)
 {
     if (name == "upper-case")
     {
         return new UpperCase();
     }
     return null;
 }
开发者ID:cstruter,项目名称:Xquery,代码行数:8,代码来源:CustomContext.cs


示例13: ResolveFunction

        public override IXsltContextFunction ResolveFunction(string prefix, string name, XPathResultType[] ArgTypes)
        {
            var func = _functions.SingleOrDefault(f => f.Name == name && f.Prefix == prefix);

            if(func != null)
                return func;
            else
                throw new InvalidOperationException("Unknown function in XPath: " + name);              
        }
开发者ID:nagyistoce,项目名称:Fhir.Profiling,代码行数:9,代码来源:XPath2Context.cs


示例14: ResolveFunction

        public override IXsltContextFunction ResolveFunction(string prefix, string name, XPathResultType[] argTypes)
        {
            if (name == "document")
            {
                return new XsltContextFunction("document");
            }

            return null;
        }
开发者ID:dshalimov,项目名称:CCDASchematronEngine,代码行数:9,代码来源:DocumentContext.cs


示例15: TriflesXPathExtensionVariable

        /// <summary>
        /// Creates the variable object.
        /// </summary>
        /// <param name="name"></param>
        /// <param name="value"></param>
        /// <param name="isLocal"></param>
        /// <param name="isParam"></param>
        /// <param name="resultType"></param>
        public TriflesXPathExtensionVariable(XName name, object value, bool isLocal = false, bool isParam = false, XPathResultType? resultType = null)
        {
            this.VariableName = name;
            this.Value = value;
            this.IsLocal = isLocal;
            this.IsParam = isParam;

            this.VariableType = resultType.HasValue ? resultType.Value : TriflesXPathData.GuessXPathResultType(value);
        }
开发者ID:falldave,项目名称:falldave-trifles-net,代码行数:17,代码来源:TriflesXPathExtensionVariable.cs


示例16: ResolveFunction

        public override IXsltContextFunction ResolveFunction(string prefix, string name, XPathResultType[] ArgTypes) {
            switch (name) {
                case "match":
                    return m_MatchFct;
                case "canCastTo":
                    return m_CanCastTo;
                default:
                    throw new NotSupportedException();
            }
		}
开发者ID:pusp,项目名称:o2platform,代码行数:10,代码来源:Context.cs


示例17: ResolveFunction

            public override IXsltContextFunction ResolveFunction(string prefix, string name, XPathResultType[] argTypes)
            {
                if (string.IsNullOrEmpty(prefix))
                {
                   if (name == "current" && argTypes.Length == 0)
                  return currentFunction;
                }

                return base.ResolveFunction(prefix, name, argTypes);
            }
开发者ID:richardschneider,项目名称:sepia,代码行数:10,代码来源:XsltQueryLanguage.cs


示例18: XsltFunction

 // Constructors
 
 public XsltFunction(string name, XPathResultType[] argTypes, XPathResultType returnType,
   Func<XsltContext, XPathNavigator, object[], object> implementation, int? minArgs = null, int? maxArgs = null)
 {
   this.name = name;
   this.argTypes = argTypes;
   this.returnType = returnType;
   this.minArgs = minArgs ?? argTypes.Length;
   this.maxArgs = maxArgs ?? argTypes.Length;
   this.implementation = implementation;
 }
开发者ID:jogibear9988,项目名称:ormbattle,代码行数:12,代码来源:XsltFunction.cs


示例19: XPathParser

 static XPathParser()
 {
     XPathResultType[] typeArray5 = new XPathResultType[3];
     typeArray5[0] = XPathResultType.String;
     temparray6 = typeArray5;
     temparray7 = new XPathResultType[] { XPathResultType.String, XPathResultType.String, XPathResultType.String };
     temparray8 = new XPathResultType[] { XPathResultType.Boolean };
     temparray9 = new XPathResultType[1];
     functionTable = CreateFunctionTable();
     AxesTable = CreateAxesTable();
 }
开发者ID:pritesh-mandowara-sp,项目名称:DecompliedDotNetLibraries,代码行数:11,代码来源:XPathParser.cs


示例20: ResolveFunction

        public override IXsltContextFunction ResolveFunction(string prefix, string name,
                                                             XPathResultType[] argTypes)
        {
            IXsltContextFunction function = null;

            if (this.functions.TryGetValue(prefix + ":" + name, out function))
            {
                return function;
            }

            return null;
        }
开发者ID:abclassic,项目名称:LBi.LostDoc,代码行数:12,代码来源:CustomXsltContext.cs



注:本文中的XPathResultType类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C# XRootNamespace类代码示例发布时间:2022-05-24
下一篇:
C# XPathResult类代码示例发布时间:2022-05-24
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap