当前位置: 首页>>代码示例>>C#>>正文


C# IList.AsArray方法代码示例

本文整理汇总了C#中IList.AsArray方法的典型用法代码示例。如果您正苦于以下问题:C# IList.AsArray方法的具体用法?C# IList.AsArray怎么用?C# IList.AsArray使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在IList的用法示例。


在下文中一共展示了IList.AsArray方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: GlobalCode

        /// <summary>
        /// Initializes a new instance of the GlobalCode class.
        /// </summary>
        public GlobalCode(IList<Statement>/*!*/ statements, SourceUnit/*!*/ sourceUnit)
        {
            Debug.Assert(statements != null && sourceUnit != null);

            this.sourceUnit = sourceUnit;
            this.statements = statements.AsArray();
        }
开发者ID:dw4dev,项目名称:Phalanger,代码行数:10,代码来源:GlobalCode.cs

示例2: EchoStmt

		public EchoStmt(Text.Span span, IList<Expression>/*!*/ parameters)
            : base(span)
		{
			Debug.Assert(parameters != null);
			this.parameters = parameters.AsArray();
            this.isHtmlCode = false;
		}
开发者ID:dw4dev,项目名称:Phalanger,代码行数:7,代码来源:EchoStmt.cs

示例3: SwitchStmt

		public SwitchStmt(Text.Span span, Expression/*!*/ switchValue, IList<SwitchItem>/*!*/ switchItems)
			: base(span)
		{
			Debug.Assert(switchValue != null && switchItems != null);

			this.switchValue = switchValue;
			this.switchItems = switchItems.AsArray();
		}
开发者ID:dw4dev,项目名称:Phalanger,代码行数:8,代码来源:SwitchStmt.cs

示例4: TryStmt

        public TryStmt(Text.Span p, IList<Statement>/*!*/ statements, List<CatchItem> catches, FinallyItem finallyItem)
			: base(p)
		{
            Debug.Assert(statements != null);
            
			this.statements = statements.AsArray();
			this.catches = catches.AsArray();
            this.finallyItem = finallyItem;
		}
开发者ID:dw4dev,项目名称:Phalanger,代码行数:9,代码来源:TryStmt.cs

示例5: BlockStmt

 public BlockStmt(Text.Span span, IList<Statement>/*!*/body)
     : base(span)
 {
     Debug.Assert(body != null);
     _statements = body.AsArray();
 }
开发者ID:dw4dev,项目名称:Phalanger,代码行数:6,代码来源:Statement.cs

示例6: FunctionDecl

		public FunctionDecl(SourceUnit/*!*/ sourceUnit,
            Text.Span span, Text.Span entireDeclarationPosition, int headingEndPosition, int declarationBodyPosition,
			bool isConditional, Scope scope, PhpMemberAttributes memberAttributes, string/*!*/ name, NamespaceDecl ns,
			bool aliasReturn, List<FormalParam>/*!*/ formalParams, List<FormalTypeParam>/*!*/ genericParams,
			IList<Statement>/*!*/ body, List<CustomAttribute> attributes)
			: base(span)
		{
			Debug.Assert(genericParams != null && name != null && formalParams != null && body != null);

			this.name = new Name(name);
			this.ns = ns;
			this.signature = new Signature(aliasReturn, formalParams);
			this.typeSignature = new TypeSignature(genericParams);
			if (attributes != null && attributes.Count != 0)
                this.Attributes = new CustomAttributes(attributes);
			this.body = body.AsArray();
			this.entireDeclarationPosition = entireDeclarationPosition;
            this.headingEndPosition = headingEndPosition;
            this.declarationBodyPosition = declarationBodyPosition;
            this.IsConditional = isConditional;
            this.MemberAttributes = memberAttributes;
            this.Scope = scope;
            this.SourceUnit = sourceUnit;
		}
开发者ID:parv0888,项目名称:Phalanger,代码行数:24,代码来源:FunctionDecl.cs

示例7: Signature

		public Signature(bool aliasReturn, IList<FormalParam>/*!*/ formalParams)
		{
			this.aliasReturn = aliasReturn;
			this.formalParams = formalParams.AsArray();
		}
开发者ID:parv0888,项目名称:Phalanger,代码行数:5,代码来源:FunctionDecl.cs

示例8: TypeSignature

		public TypeSignature(IList<FormalTypeParam>/*!!*/ typeParams)
		{
			Debug.Assert(typeParams != null);
			this.typeParams = typeParams.AsArray();
		}
开发者ID:dw4dev,项目名称:Phalanger,代码行数:5,代码来源:TypeDecl.cs

示例9: MethodDecl

        public MethodDecl(Text.Span span, Text.Span entireDeclarationPosition, int headingEndPosition, int declarationBodyPosition, 
			string name, bool aliasReturn, IList<FormalParam>/*!*/ formalParams, IList<FormalTypeParam>/*!*/ genericParams, 
			IList<Statement> body, PhpMemberAttributes modifiers, IList<ActualParam> baseCtorParams, 
			List<CustomAttribute> attributes)
            : base(span, attributes)
        {
            Debug.Assert(genericParams != null && formalParams != null);

            this.modifiers = modifiers;
            this.name = new Name(name);
            this.signature = new Signature(aliasReturn, formalParams);
            this.typeSignature = new TypeSignature(genericParams);
            this.body = (body != null) ? body.AsArray() : null;
            this.baseCtorParams = (baseCtorParams != null) ? baseCtorParams.AsArray() : null;
            this.entireDeclarationSpan = entireDeclarationPosition;
            this.headingEndPosition = headingEndPosition;
            this.declarationBodyPosition = declarationBodyPosition;
        }
开发者ID:dw4dev,项目名称:Phalanger,代码行数:18,代码来源:TypeDecl.cs

示例10: FinallyItem

 public FinallyItem(Text.Span span, IList<Statement>/*!*/statements)
     : base(span)
 {
     this.statements = statements.AsArray();
 }
开发者ID:dw4dev,项目名称:Phalanger,代码行数:5,代码来源:TryStmt.cs

示例11: CatchItem

        public CatchItem(Text.Span p, DirectTypeRef tref, DirectVarUse/*!*/ variable,
			IList<Statement>/*!*/ statements)
			: base(p)
		{
			Debug.Assert(variable != null && statements != null);

			this.tref = tref;
			this.variable = variable;
			this.statements = statements.AsArray();
		}
开发者ID:dw4dev,项目名称:Phalanger,代码行数:10,代码来源:TryStmt.cs

示例12: LambdaFunctionExpr

        public LambdaFunctionExpr(SourceUnit/*!*/ sourceUnit,
            Text.Span span, Text.Span entireDeclarationPosition, int headingEndPosition, int declarationBodyPosition,
            Scope scope, NamespaceDecl ns,
            bool aliasReturn, List<FormalParam>/*!*/ formalParams, List<FormalParam> useParams,
            IList<Statement>/*!*/ body)
            : base(span)
        {
            Debug.Assert(formalParams != null && body != null);
            Debug.Assert(sourceUnit != null);

            this.sourceUnit = sourceUnit;
            
            this.ns = ns;
            this.signature = new Signature(aliasReturn, formalParams);
            this.useParams = useParams;
            //this.typeSignature = new TypeSignature(genericParams);
            //this.attributes = new CustomAttributes(attributes);
            this.body = body.AsArray();
            this.entireDeclarationPosition = entireDeclarationPosition;
            this.headingEndPosition = headingEndPosition;
            this.declarationBodyPosition = declarationBodyPosition;
        }
开发者ID:parv0888,项目名称:Phalanger,代码行数:22,代码来源:LambdaFunctionExpr.cs

示例13: CallSignature

        /// <summary>
        /// Initialize new instance of <see cref="CallSignature"/>.
        /// </summary>
        /// <param name="parameters">List of parameters.</param>
        /// <param name="genericParams">List of type parameters for generics.</param>
        public CallSignature(IList<ActualParam> parameters, IList<TypeRef> genericParams)
		{
			this.parameters = parameters.AsArray();
            this.GenericParams = genericParams.AsArray();
		}        
开发者ID:dw4dev,项目名称:Phalanger,代码行数:10,代码来源:CallSignature.cs

示例14: SwitchItem

		protected SwitchItem(Text.Span span, IList<Statement>/*!*/ statements)
			: base(span)
		{
			Debug.Assert(statements != null);
			this.statements = statements.AsArray();
		}
开发者ID:dw4dev,项目名称:Phalanger,代码行数:6,代码来源:SwitchStmt.cs

示例15: ArrayEx

		public ArrayEx(Text.Span span, IList<Item>/*!*/items)
			: base(span)
		{
			Debug.Assert(items != null);
			this.items = items.AsArray();
		}
开发者ID:dw4dev,项目名称:Phalanger,代码行数:6,代码来源:ArrayEx.cs


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