if (!Modifier.isAbstract(commandClass.getModifiers())) { command = (Command) commandClass.newInstance(); Iterator iter = command.getActionNames().iterator(); while (iter.hasNext()) { String commandName = (String) iter.next(); Set commandObjects = (Set) commands.get(commandName); if (commandObjects == null) { commandObjects = new HashSet(); commands.put(commandName, commandObjects); } commandObjects.add(command);
if (!Modifier.isAbstract(commandClass.getModifiers())) { command = (Command) commandClass.newInstance(); Iterator iter = command.getActionNames().iterator(); while (iter.hasNext()) { String commandName = (String) iter.next(); Set commandObjects = (Set) commands.get(commandName); if (commandObjects == null) { commandObjects = new HashSet(); commands.put(commandName, commandObjects); } commandObjects.add(command);
Clone fragments detected by clone detection tool
File path: /jakarta-jmeter-2.3.2/src/org/apache/jmeter/gui/action/ActionRouter.java File path: /jakarta-jmeter-2.3.2/src/org/apache/jmeter/report/gui/action/ReportActionRouter.java
Method name: Method name:
Number of AST nodes: 0 Number of AST nodes: 0
1
if (!Modifier.isAbstract(commandClass.getModifiers())) {
1
if (!Modifier.isAbstract(commandClass.getModifiers())) {
2
                        command = (Command) commandClass.newInstance();
2
                        command = (Command) commandClass.newInstance();
3
                        Iterator iter = command.getActionNames().iterator();
3
                        Iterator iter = command.getActionNames().iterator();
4
                        while (iter.hasNext()) {
4
                        while (iter.hasNext()) {
5
                            String commandName = (String) iter.next();
5
                            String commandName = (String) iter.next();
6
                            Set commandObjects = (Set) commands.get(commandName);
6
                            Set commandObjects = (Set) commands.get(commandName);
7
                            if (commandObjects == null) {
7
                            if (commandObjects == null) {
8
                                commandObjects = new HashSet();
8
                                commandObjects = new HashSet();
9
                                commands.put(commandName, commandObjects);
9
                                commands.put(commandName, commandObjects);
10
                            }
10
                            }
11
                            commandObjects.add(command);
11
                            commandObjects.add(command);
12
                        
12
                        
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