for(int i = 0; i < deps.size(); i++) { Dependency dep = (Dependency)deps.elementAt(i); dep.satisfy(roster,installDirectory,downloadSource); }
for(int i = 0; i < listeners.size(); i++) { ListDataListener listener = (ListDataListener) listeners.elementAt(i); listener.intervalRemoved(new ListDataEvent(this, ListDataEvent.INTERVAL_REMOVED, index1,index2)); }
Clone fragments detected by clone detection tool
File path: /jEdit-4.2/src/org/gjt/sp/jedit/pluginmgr/PluginList.java File path: /jEdit-4.2/src/org/gjt/sp/util/Log.java
Method name: void satisfyDependencies(Roster, String, boolean) Method name: void fireIntervalRemoved(int, int)
Number of AST nodes: 3 Number of AST nodes: 3
1
for(int i = 0; i < deps.size(); i++)
1
for(int i = 0; i < listeners.size(); i++)
2
			{
2
			{
3
				Dependency dep = (Dependency)deps.elementAt(i);
3
				
4
				dep.satisfy(roster,installDirectory,downloadSource
4
ListDataListener listener = (ListDataListener)
5
					listeners.elementAt(i);
6
				listener.intervalRemoved(new ListDataEvent(this,
7
					ListDataEvent.INTERVAL_REMOVED,
5
);
8
					index1,index2));
6
			}
9
			}
Summary
Number of common nesting structure subtrees1
Number of refactorable cases0
Number of non-refactorable cases1
Time elapsed for finding largest common nesting structure subtrees (ms)0.2
Clones locationClones are in different classes
Number of node comparisons9
  1. {Non-refactorable}
    Mapping Summary
    Number of mapped statements1
    Number of unmapped statements in the first code fragment2
    Number of unmapped statements in the second code fragment2
    Time elapsed for statement mapping (ms)1.4
    Clone typeType 2
    Mapped Statements
    ID Statement ID Statement
    1
    for (int i = 0; i < deps.size(); i++)
    1
    for (int i = 0; i < deps.size(); i++)
    1
    for (int i = 0; i < listeners.size(); i++)
    Differences
    Expression1Expression2Difference
    depslistenersVARIABLE_NAME_MISMATCH
    1
    for (int i = 0; i < listeners.size(); i++)
                                                                                                                                                
    2
    ListDataListener listener = (ListDataListener)listeners.elementAt(i);
    Preondition Violations
    Unmatched statement ListDataListener listener=(ListDataListener)listeners.elementAt(i); cannot be moved before or after the extracted code, because it has dependencies to/from statements that will be extracted
    2
    ListDataListener listener = (ListDataListener)listeners.elementAt(i);
    2
    Dependency dep = (Dependency)deps.elementAt(i);
    2
    Dependency dep = (Dependency)deps.elementAt(i);
    Preondition Violations
    Unmatched statement Dependency dep=(Dependency)deps.elementAt(i); cannot be moved before or after the extracted code, because it has dependencies to/from statements that will be extracted
                                                                                                    
                                                                                                                                                                                                        
    3
    listener.intervalRemoved(new ListDataEvent(this, ListDataEvent.INTERVAL_REMOVED, index1, index2));
    3
    dep.satisfy(roster, installDirectory, downloadSource);
    3
    dep.satisfy(roster, installDirectory, downloadSource);
    Preondition Violations
    Unmatched statement dep.satisfy(roster,installDirectory,downloadSource); cannot be moved before or after the extracted code, because it has dependencies to/from statements that will be extracted
    Unmatched statement dep.satisfy(roster,installDirectory,downloadSource); cannot be moved before or after the extracted code, because it throws exception(s) that should be caught by a try block that will be extracted
                                                                                                                  
    Precondition Violations (5)
    Row Violation
    1Unmatched statement ListDataListener listener=(ListDataListener)listeners.elementAt(i); cannot be moved before or after the extracted code, because it has dependencies to/from statements that will be extracted
    2Unmatched statement Dependency dep=(Dependency)deps.elementAt(i); cannot be moved before or after the extracted code, because it has dependencies to/from statements that will be extracted
    3Unmatched statement dep.satisfy(roster,installDirectory,downloadSource); cannot be moved before or after the extracted code, because it has dependencies to/from statements that will be extracted
    4Unmatched statement dep.satisfy(roster,installDirectory,downloadSource); cannot be moved before or after the extracted code, because it throws exception(s) that should be caught by a try block that will be extracted
    5The refactoring of the clones is infeasible, because the number of macthed statements is equal to zero