Beispiel #1
0
 protected virtual bool VisitTransactionName(TransactionStatement statement)
 {
     if (statement.Name != null)
     {
         VisitNameToken(statement.Name);
         return(true);
     }
     if (statement.Parameter != null)
     {
         State.Write(statement.Parameter.Name);
         State.Parameters.Add(statement.Parameter);
         return(true);
     }
     return(false);
 }
Beispiel #2
0
        public TransactionStatement ParseTransactionStatement(TransactionStatementContext node)
        {
            TransactionStatement statement = new TransactionStatement();

            statement.Content = new TokenInfo(node);

            if (node.startTransaction() != null)
            {
                statement.CommandType = TransactionCommandType.BEGIN;
            }
            else if (node.commitWork() != null)
            {
                statement.CommandType = TransactionCommandType.COMMIT;
            }
            else if (node.rollbackStatement() != null)
            {
                statement.CommandType = TransactionCommandType.ROLLBACK;
            }

            return(statement);
        }
 public override void ExplicitVisit(TransactionStatement fragment)
 {
     _fragments.Add(fragment);
 }
 public sealed override void ExplicitVisit(TransactionStatement node)
 {
     base.ExplicitVisit(node);
 }
Beispiel #5
0
 public override void ExplicitVisit(TransactionStatement node) { this.action(node); }