Exemple #1
0
 public virtual void VisitTryCatchFinallyStatement(TryCatchFinallyStatement tryCatchFinallyStatement)
 {
     VisitStatement(tryCatchFinallyStatement);
     Visit(tryCatchFinallyStatement.Try);
     Visit(tryCatchFinallyStatement.Catch);
     Visit(tryCatchFinallyStatement.Finally);
 }
Exemple #2
0
        protected virtual void Write(IndentedTextWriter writer, TryCatchFinallyStatement statement, WriteStatementOptions options)
        {
            writer.WriteLine("try");
            Write(writer, statement.Try);

            if (statement.Catch != null)
            {
                Write(writer, statement.Catch);
            }

            if (statement.Finally != null)
            {
                writer.WriteLine("finally");
                Write(writer, statement.Finally);
            }
        }