View Javadoc

1   /*
2    *  soapUI, copyright (C) 2006 eviware.com 
3    *
4    *  soapUI is free software; you can redistribute it and/or modify it under the 
5    *  terms of the GNU Lesser General Public License as published by the Free Software Foundation; 
6    *  either version 2.1 of the License, or (at your option) any later version.
7    *
8    *  soapUI is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without 
9    *  even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 
10   *  See the GNU Lesser General Public License for more details at gnu.org.
11   */
12  
13  package com.eviware.soapui.model.testsuite;
14  
15  /***
16   * Listener for LoadTest run events
17   * 
18   * @author Ole.Matzura
19   */
20  
21  public interface LoadTestRunListener
22  {
23  	/***
24  	 * Called before a load-test is about to be run
25  	 * 
26  	 * @param loadTestRunner
27  	 * @param context
28  	 */
29  	
30  	public void beforeLoadTest( LoadTestRunner loadTestRunner, LoadTestRunContext context );
31  	
32  	/***
33  	 * Called after all initial loadtest threads have been started 
34  	 * @param loadTestRunner
35  	 * @param context
36  	 */
37  	
38  	public void loadTestStarted( LoadTestRunner loadTestRunner, LoadTestRunContext context );
39  	
40  	/***
41  	 * Called before the execution of a testcase
42  	 * 
43  	 * @param loadTestRunner
44  	 * @param context
45  	 * @param testRunner
46  	 * @param runContext
47  	 */
48  	
49  	public void beforeTestCase( LoadTestRunner loadTestRunner, LoadTestRunContext context, TestRunner testRunner, TestRunContext runContext );
50  
51  	/***
52  	 * Called before the execution of a teststep
53  	 * 
54  	 * @param loadTestRunner
55  	 * @param context
56  	 * @param testRunner
57  	 * @param runContext
58  	 * @param testStep
59  	 */
60  	
61  	public void beforeTestStep( LoadTestRunner loadTestRunner, LoadTestRunContext context, TestRunner testRunner, TestRunContext runContext, TestStep testStep );
62  
63  	/***
64  	 * Called after the execution of a teststep 
65  	 * 
66  	 * @param loadTestRunner
67  	 * @param context
68  	 * @param testRunner
69  	 * @param runContext
70  	 * @param testStepResult
71  	 */
72  	
73  	public void afterTestStep( LoadTestRunner loadTestRunner, LoadTestRunContext context, TestRunner testRunner, TestRunContext runContext, TestStepResult testStepResult );
74  	
75  	/***
76  	 * Called after the execution of a testcase
77  	 * 
78  	 * @param loadTestRunner
79  	 * @param context
80  	 * @param testRunner
81  	 * @param runContext
82  	 */
83  	
84  	public void afterTestCase( LoadTestRunner loadTestRunner, LoadTestRunContext context, TestRunner testRunner, TestRunContext runContext );
85  	
86  	/***
87  	 * Called when a loadtest has been stopped for some reason
88  	 * 
89  	 * @param loadTestRunner
90  	 * @param context
91  	 */
92  	
93  	public void loadTestStopped( LoadTestRunner loadTestRunner, LoadTestRunContext context );
94  
95  	/***
96  	 * Called after the execution of a loadtest when all threads have terminated 
97  	 * 
98  	 * @param loadTestRunner
99  	 * @param context
100 	 */
101 	public void afterLoadTest( LoadTestRunner loadTestRunner, LoadTestRunContext context );
102 }