Start() { } /** * Gets the ActionNames attribute of the Start object. * * @return the ActionNames value */ public Set getActionNames() { return commands; } public void doAction(ActionEvent e) { if (e.getActionCommand().equals(ActionNames.ACTION_START)) { popupShouldSave(e); startEngine(); } else if (e.getActionCommand().equals(ActionNames.ACTION_STOP)) { if (engine != null) { GuiPackage.getInstance().getMainFrame().showStoppingMessage(""); engine.stopTest(); engine = null; } } else if (e.getActionCommand().equals(ActionNames.ACTION_SHUTDOWN)) { if (engine != null) { GuiPackage.getInstance().getMainFrame().showStoppingMessage(""); engine.askThreadsToStop(); engine = null; } }
ReportStart() { } /** * Gets the ActionNames attribute of the Start object. * * @return the ActionNames value */ public Set getActionNames() { return commands; } public void doAction(ActionEvent e) { if (e.getActionCommand().equals(ActionNames.ACTION_START)) { popupShouldSave(e); startEngine(); } else if (e.getActionCommand().equals(ActionNames.ACTION_STOP)) { if (engine != null) { ReportGuiPackage.getInstance().getMainFrame().showStoppingMessage(""); engine.stopTest(); engine = null; } } else if (e.getActionCommand().equals(ActionNames.ACTION_SHUTDOWN)) { if (engine != null) { ReportGuiPackage.getInstance().getMainFrame().showStoppingMessage(""); engine.askThreadsToStop(); engine = null; } }
Clone fragments detected by clone detection tool
File path: /jakarta-jmeter-2.3.2/src/org/apache/jmeter/gui/action/Start.java File path: /jakarta-jmeter-2.3.2/src/org/apache/jmeter/report/gui/action/ReportStart.java
Method name: Method name:
Number of AST nodes: 0 Number of AST nodes: 0
1
Start() {
1
ReportStart() {
2
	}
2
	}
3
	/**
3
	/**
4
	 * Gets the ActionNames attribute of the Start object.
4
	 * Gets the ActionNames attribute of the Start object.
5
	 * 
5
	 * 
6
	 * @return the ActionNames value
6
	 * @return the ActionNames value
7
	 */
7
	 */
8
	public Set getActionNames() {
8
	public Set getActionNames() {
9
		return commands;
9
		return commands;
10
	}
10
	}
11
	public void doAction(ActionEvent e) {
11
	public void doAction(ActionEvent e) {
12
		if (e.getActionCommand().equals(ActionNames.ACTION_START)) {
12
		if (e.getActionCommand().equals(ActionNames.ACTION_START)) {
13
			popupShouldSave(e);
13
			popupShouldSave(e);
14
			startEngine();
14
			startEngine();
15
		} else if (e.getActionCommand().equals(ActionNames.ACTION_STOP)) {
15
		} else if (e.getActionCommand().equals(ActionNames.ACTION_STOP)) {
16
			if (engine != null) {
16
			if (engine != null) {
17
				GuiPackage.getInstance().getMainFrame().showStoppingMessage("");
17
				ReportGuiPackage.getInstance().getMainFrame().showStoppingMessage("");
18
				engine.stopTest();
18
				engine.stopTest();
19
				engine = null;
19
				engine = null;
20
			}
20
			}
21
		} else if (e.getActionCommand().equals(ActionNames.ACTION_SHUTDOWN)) {
21
		} else if (e.getActionCommand().equals(ActionNames.ACTION_SHUTDOWN)) {
22
			if (engine != null) {
22
			if (engine != null) {
23
				GuiPackage.getInstance().getMainFrame().showStoppingMessage("");
23
				ReportGuiPackage.getInstance().getMainFrame().showStoppingMessage("");
24
				engine.askThreadsToStop();
24
				engine.askThreadsToStop();
25
				engine = null;
25
				engine = null;
26
			}
26
			}
27
		}
27
		}
28
	
28
	
Summary
Number of common nesting structure subtrees0
Number of refactorable cases0
Number of non-refactorable cases0
Time elapsed for finding largest common nesting structure subtrees (ms)0.0
Clones location
Number of node comparisons0