Inheritance: LoopControlStatement
Example #1
0
        protected override SqlStatement VisitContinue(ContinueStatement statement)
        {
            if (!String.Equals(label, statement.Label))
                breakFound = true;

            return base.VisitContinue(statement);
        }
Example #2
0
 protected virtual SqlStatement VisitContinue(ContinueStatement statement)
 {
     return new ContinueStatement(statement.Label, statement.WhenExpression);
 }
 public void ContinueWhen()
 {
     var statement = new ContinueStatement(SqlExpression.Constant(true));
     SerializeAndAssert(statement, (serialized, deserialized) => {
         Assert.IsNotNull(deserialized);
         Assert.IsNull(deserialized.Label);
         Assert.IsNotNull(deserialized.WhenExpression);
         Assert.IsInstanceOf<SqlConstantExpression>(deserialized.WhenExpression);
     });
 }
 public void ContinueLabel()
 {
     var statement = new ContinueStatement("test");
     SerializeAndAssert(statement, (serialized, deserialized) => {
         Assert.IsNotNull(deserialized);
         Assert.IsNotNull(deserialized.Label);
         Assert.AreEqual(serialized.Label, deserialized.Label);
         Assert.IsNull(deserialized.WhenExpression);
     });
 }