PageRenderTime 23ms CodeModel.GetById 16ms app.highlight 3ms RepoModel.GetById 1ms app.codeStats 0ms

/src/NUnit/UiException/Controls/IErrorDisplay.cs

#
C# | 51 lines | 15 code | 5 blank | 31 comment | 0 complexity | 0f3541110271e12c06cd22d29d35bcbc MD5 | raw file
 1// ****************************************************************
 2// This is free software licensed under the NUnit license. You may
 3// obtain a copy of the license at http://nunit.org
 4// ****************************************************************
 5
 6using System;
 7using System.Collections.Generic;
 8using System.Text;
 9using System.Drawing;
10using System.Windows.Forms;
11
12namespace NUnit.UiException.Controls
13{
14    /// <summary>
15    /// This interface describes a feature that can be added to the ErrorWindow
16    /// in order to show relevant information about failures/errors after a
17    /// test suite run.
18    ///     Clients who wants to add their own display should implement this
19    /// interface and register their instance to ErrorBrowser at run-time.
20    /// 
21    /// Direct known implementations are:
22    ///     StackTraceDisplay
23    ///     SourceCodeDisplay
24    /// </summary>
25    public interface IErrorDisplay
26    {
27        /// <summary>
28        /// Gives access to the ToolStripButton that enables this display.
29        /// </summary>
30        ToolStripButton PluginItem { get; }
31
32        /// <summary>
33        /// Gives access to a possibly null collection of option controls that will
34        /// be shown when this display has the focus.
35        /// </summary>
36        ToolStripItem[] OptionItems { get; }
37
38        /// <summary>
39        /// Gives access to the content control of this display.
40        /// </summary>
41        Control Content { get; }
42
43        /// <summary>
44        /// Called whenever the user changes the error selection in the detail list.
45        /// This method is called to allow the display to update its content according
46        /// the given stack trace.
47        /// </summary>
48        /// <param name="stackTrace"></param>
49        void OnStackTraceChanged(string stackTrace);
50    }
51}