KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > apache > jmeter > reporters > gui > SummariserGui


1 // $Header: /home/cvs/jakarta-jmeter/src/core/org/apache/jmeter/reporters/gui/SummariserGui.java,v 1.3 2004/03/05 01:34:53 sebb Exp $
2
/*
3  * Copyright 2003-2004 The Apache Software Foundation.
4  *
5  * Licensed under the Apache License, Version 2.0 (the "License");
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at
8  *
9  * http://www.apache.org/licenses/LICENSE-2.0
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  * See the License for the specific language governing permissions and
15  * limitations under the License.
16  *
17 */

18
19 package org.apache.jmeter.reporters.gui;
20
21 import java.awt.BorderLayout JavaDoc;
22
23 import org.apache.jmeter.reporters.Summariser;
24 import org.apache.jmeter.processor.gui.AbstractPostProcessorGui;
25 import org.apache.jmeter.testelement.TestElement;
26
27 /**
28  * Create a summariser test element.
29  *
30  * Note:
31  * This is not really a PostProcessor, but that seems to be the closest
32  * of the existing types.
33  *
34  * @version $Revision: 1.3 $ Last updated: $Date: 2004/03/05 01:34:53 $
35  */

36 public class SummariserGui extends AbstractPostProcessorGui
37 {
38    
39     public SummariserGui()
40     {
41         super();
42         init();
43     }
44
45     public String JavaDoc getLabelResource()
46     {
47         return "summariser_title";
48     }
49     
50     public void configure(TestElement el)
51     {
52         super.configure(el);
53     }
54
55     /**
56      * @see org.apache.jmeter.gui.JMeterGUIComponent#createTestElement()
57      */

58     public TestElement createTestElement()
59     {
60         Summariser summariser = new Summariser();
61         modifyTestElement(summariser);
62         return summariser;
63     }
64
65     /**
66      * Modifies a given TestElement to mirror the data in the gui components.
67      * @see org.apache.jmeter.gui.JMeterGUIComponent#modifyTestElement(TestElement)
68      */

69     public void modifyTestElement(TestElement summariser)
70     {
71         super.configureTestElement(summariser);
72     }
73     
74     private void init()
75     {
76         setLayout(new BorderLayout JavaDoc());
77         setBorder(makeBorder());
78         
79         add(makeTitlePanel(),BorderLayout.NORTH);
80     }
81 }
82
Popular Tags