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


C# Statements类代码示例

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


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

示例1: CaseExpression

 public CaseExpression(Expression value, WhenClause/*!*/[] whenClauses, Statements elseStatements, SourceSpan location)
     : base(location)
 {
     _value = value;
     _whenClauses = whenClauses ?? WhenClause.EmptyArray;
     _elseStatements = elseStatements;
 }
开发者ID:TerabyteX,项目名称:main,代码行数:7,代码来源:CaseExpression.cs

示例2: ForLoopExpression

 public ForLoopExpression(CompoundLeftValue/*!*/ variables, Expression/*!*/ list, Statements body, SourceSpan location)
     : base(location) {
     Assert.NotNull(variables, list);
     
     _block = new BlockDefinition(null, variables, body, location);
     _list = list;
 }
开发者ID:joshholmes,项目名称:ironruby,代码行数:7,代码来源:ForLoopExpression.cs

示例3: Finalizer

        public Finalizer(LexicalScope/*!*/ definedScope, Statements statements, SourceSpan location)
            : base(location) {
            Assert.NotNull(definedScope);

            _definedScope = definedScope;
            _statements = statements;
        }
开发者ID:jxnmaomao,项目名称:ironruby,代码行数:7,代码来源:Finalizer.cs

示例4: ForLoopExpression

        public ForLoopExpression(LexicalScope/*!*/ definedScope, Parameters/*!*/ variables, Expression/*!*/ list, Statements body, SourceSpan location)
            : base(location) {
            Assert.NotNull(definedScope, variables, list);

            _block = new BlockDefinition(definedScope, variables, body, location);
            _list = list;
        }
开发者ID:jschementi,项目名称:iron,代码行数:7,代码来源:ForLoopExpression.cs

示例5: RescueClause

 public RescueClause(CompoundRightValue type, LeftValue target, Statements statements, SourceSpan location)
     : base(location) {
     _types = type.RightValues;
     _splatType = type.SplattedValue;
     _target = target;
     _statements = statements;
 }
开发者ID:aceptra,项目名称:ironruby,代码行数:7,代码来源:RescueClause.cs

示例6: BlockExpression

        internal BlockExpression(Statements/*!*/ statements, SourceSpan location)
            : base(location) {
            Assert.NotNull(statements);
            Debug.Assert(statements.Count > 1);

            _statements = statements;
        }
开发者ID:ExpertsInside,项目名称:IronSP,代码行数:7,代码来源:BlockExpression.cs

示例7: StatementFor

 /// <summary>
 /// Creates a new for loop statement. Usage:
 /// for 'identifier' in 'firstExpression' .. 'secondExpression' do 'statements' end for;
 /// </summary>
 /// <param name="identifier">Iterator's identifier</param>
 /// <param name="firstExpression">Starting value</param>
 /// <param name="secondExpression">Ending value</param>
 /// <param name="statements">Statements to execute</param>
 public StatementFor(string identifier, Expression firstExpression, Expression secondExpression, Statements statements)
 {
     Identifier = identifier;
     FirstExpression = firstExpression;
     SecondExpression = secondExpression;
     Statements = statements;
 }
开发者ID:janivihervas,项目名称:mini-pl-interpreter,代码行数:15,代码来源:StatementFor.cs

示例8: ElseIfClause

 public ElseIfClause(Expression condition, Statements/*!*/ statements, SourceSpan location)
     : base(location)
 {
     Assert.NotNull(statements);
     _statements = statements;
     _condition = condition;
 }
开发者ID:TerabyteX,项目名称:main,代码行数:7,代码来源:ElseIfClause.cs

示例9: CaseExpression

        public CaseExpression(Expression value, List<WhenClause>/*!*/ whenClauses, Statements elseStatements, SourceSpan location)
            : base(location) {
            ContractUtils.RequiresNotNull(whenClauses, "whenClauses");

            _value = value;
            _whenClauses = whenClauses;
            _elseStatements = elseStatements;
        }
开发者ID:joshholmes,项目名称:ironruby,代码行数:8,代码来源:CaseExpression.cs

示例10: BlockDefinition

        public BlockDefinition(LexicalScope/*!*/ definedScope, CompoundLeftValue/*!*/ parameters, Statements/*!*/ body, SourceSpan location)
            : base(location) {
            Assert.NotNull(definedScope, parameters, body);

            _definedScope = definedScope;
            _body = body;
            _parameters = parameters;
        }
开发者ID:nieve,项目名称:ironruby,代码行数:8,代码来源:BlockDefinition.cs

示例11: RescueClause

        private readonly Expression[] _types; // might be empty, might include SplattedArgument expressions

        #endregion Fields

        #region Constructors

        public RescueClause(Expression/*!*/[]/*!*/ types, LeftValue target, Statements statements, SourceSpan location)
            : base(location)
        {
            Assert.NotNullItems(types);
            _types = types;
            _target = target;
            _statements = statements;
        }
开发者ID:TerabyteX,项目名称:main,代码行数:14,代码来源:RescueClause.cs

示例12: BlockDefinition

        public BlockDefinition(LexicalScope/*!*/ definedScope, Parameters parameters, Statements/*!*/ body, SourceSpan location)
            : base(location) {
            Assert.NotNull(definedScope, body);

            _definedScope = definedScope;
            _body = body;
            _parameters = parameters ?? Parameters.Empty; 
        }
开发者ID:jschementi,项目名称:iron,代码行数:8,代码来源:BlockDefinition.cs

示例13: UnlessExpression

        public UnlessExpression(Expression/*!*/ condition, Statements/*!*/ statements, ElseIfClause elseClause, SourceSpan location)
            : base(location) {
            ContractUtils.RequiresNotNull(condition, "condition");
            ContractUtils.RequiresNotNull(statements, "statements");
            ContractUtils.Requires(elseClause == null || elseClause.Condition == null, "elseClause", "No condition allowed.");

            _statements = statements;
            _condition = condition;
            _elseClause = elseClause;
        }
开发者ID:aslakhellesoy,项目名称:ironruby,代码行数:10,代码来源:UnlessExpression.cs

示例14: WhileLoopExpression

        public WhileLoopExpression(Expression/*!*/ condition, bool isWhileLoop, bool isPostTest, Statements/*!*/ statements, SourceSpan location)
            : base(location) {

            ContractUtils.RequiresNotNull(condition, "condition");
            ContractUtils.RequiresNotNull(statements, "statements");

            _condition = condition;
            _isWhileLoop = isWhileLoop;
            _isPostTest = isPostTest;
            _statements = statements;
        }
开发者ID:ExpertsInside,项目名称:IronSP,代码行数:11,代码来源:WhileLoopExpression.cs

示例15: Body

        public Body(Statements/*!*/ statements, List<RescueClause> rescueClauses, Statements elseStatements,
            Statements ensureStatements, SourceSpan location)
            : base(location) {

            Assert.NotNull(statements);

            _statements = statements;
            _rescueClauses = rescueClauses;
            _elseStatements = elseStatements;
            _ensureStatements = ensureStatements;
        }
开发者ID:jcteague,项目名称:ironruby,代码行数:11,代码来源:Body.cs


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