/** * Create a new TransactionControllerGui instance. */ public TransactionControllerGui() { init(); }
/** * Initialize the GUI components and layout for this component. */ private void init() { // WARNING: called from ctor so must not be overridden (i.e. must be private or final) setLayout(new VerticalLayout(5, VerticalLayout.BOTH, VerticalLayout.TOP)); setBorder(makeBorder()); add(makeTitlePanel()); generateParentSample = new JCheckBox(JMeterUtils.getResString("transaction_controller_parent")); // $NON-NLS-1$ add(CheckBoxPanel.wrap(generateParentSample)); includeTimers = new JCheckBox(JMeterUtils.getResString("transaction_controller_include_timers"), true); // $NON-NLS-1$ add(CheckBoxPanel.wrap(includeTimers)); } }
@Override public void modifyTestElement(TestElement el) { configureTestElement(el); ((TransactionController) el).setGenerateParentSample(generateParentSample.isSelected()); TransactionController tc = (TransactionController) el; tc.setGenerateParentSample(generateParentSample.isSelected()); tc.setIncludeTimers(includeTimers.isSelected()); }
@Override public TestElement createTestElement() { TransactionController lc = new TransactionController(); lc.setIncludeTimers(false); // change default for new test elements configureTestElement(lc); return lc; }