예제 #1
0
 public virtual void Error( string msg, Exception e )
 {
     if ( _listener != null )
     {
         _listener.Error( msg, e );
     }
     else
     {
         Console.Error.WriteLine( "StringTemplate: " + msg );
         if ( e != null )
         {
             e.PrintStackTrace();
         }
     }
 }
예제 #2
0
 static void RawError( String msg, Exception e )
 {
     RawError( msg );
     e.PrintStackTrace( Console.Error );
 }
예제 #3
0
 public virtual void Error( string s, Exception e )
 {
     Console.Error.WriteLine( s );
     if ( e != null )
     {
         e.PrintStackTrace( Console.Error );
     }
 }
예제 #4
0
 public void Error( string msg, Exception e )
 {
     n++;
     if ( n > 1 )
     {
         errorOutput.Append( '\n' );
     }
     if ( e != null )
     {
         StringWriter duh = new StringWriter();
         e.PrintStackTrace( duh );
         errorOutput.Append( msg + ": " + duh.ToString() );
     }
     else
     {
         errorOutput.Append( msg );
     }
 }