File path: /jakarta-jmeter-2.3.2/src/org/apache/jmeter/gui/util/MenuFactory.java | File path: /jakarta-jmeter-2.3.2/src/org/apache/jmeter/gui/util/ReportMenuFactory.java | |||
Method name: JMenuItem makeMenuItem(String, String, String)
|
Method name: JMenuItem makeMenuItem(String, String, String)
|
|||
Number of AST nodes: 6 | Number of AST nodes: 6 | |||
1 | JMenuItem newMenuChoice = new JMenuItem(label);↵ | 1 | JMenuItem newMenuChoice = new JMenuItem(label);↵ | |
2 | newMenuChoice.setName(name);↵ | 2 | newMenuChoice.setName(name);↵ | |
3 | newMenuChoice.addActionListener(ActionRouter.getInstance());↵ | 3 | newMenuChoice.addActionListener(ReportActionRouter.getInstance());↵ | |
4 | if (actionCommand != null) {↵ | 4 | if (actionCommand != null) {↵ | |
5 | newMenuChoice.setActionCommand(actionCommand);↵ | 5 | newMenuChoice.setActionCommand(actionCommand);↵ | |
6 | }↵ | 6 | }↵ | |
7 | return newMenuChoice; | 7 |
| |
See real code fragment | See real code fragment |
Number of common nesting structure subtrees | 1 |
Number of refactorable cases | 0 |
Number of non-refactorable cases | 1 |
Time elapsed for finding largest common nesting structure subtrees (ms) | 0.1 |
Clones location | Clones are in different classes |
Number of node comparisons | 14 |
Number of mapped statements | 6 |
Number of unmapped statements in the first code fragment | 0 |
Number of unmapped statements in the second code fragment | 0 |
Time elapsed for statement mapping (ms) | 1.1 |
Clone type | Type 2 |
ID | Statement | ID | Statement | ||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
1 | JMenuItem newMenuChoice = new JMenuItem(label); | 1 | JMenuItem newMenuChoice = new JMenuItem(label); | ||||||||||||||||
2 | newMenuChoice.setName(name); | 2 | newMenuChoice.setName(name); | ||||||||||||||||
3 | newMenuChoice.addActionListener(ActionRouter.getInstance()); |
| 3 | newMenuChoice.addActionListener(ReportActionRouter.getInstance()); | |||||||||||||||
4 | if (actionCommand != null) | 4 | if (actionCommand != null) | ||||||||||||||||
5 | newMenuChoice.setActionCommand(actionCommand); | 5 | newMenuChoice.setActionCommand(actionCommand); | ||||||||||||||||
6 | return newMenuChoice; | 6 | return newMenuChoice; |
Row | Violation |
---|---|
1 | Type org.apache.jmeter.gui.action.ActionRouter of variable ActionRouter.getInstance() does not match with type org.apache.jmeter.report.gui.action.ReportActionRouter of variable ReportActionRouter.getInstance() |
2 | Type org.apache.jmeter.gui.action.ActionRouter of variable ActionRouter does not match with type org.apache.jmeter.report.gui.action.ReportActionRouter of variable ReportActionRouter |