startingEdit = true; startEditing(); startingEdit = false;
skipNext = true; incrementCurrent(); return element;
Clone fragments detected by clone detection tool
File path: /jakarta-jmeter-2.3.2/src/org/apache/jmeter/testbeans/gui/ComboStringEditor.java File path: /jakarta-jmeter-2.3.2/src/org/apache/jmeter/control/InterleaveControl.java
Method name: void itemStateChanged(ItemEvent) Method name: Sampler nextIsASampler(Sampler)
Number of AST nodes: 3 Number of AST nodes: 3
1
startingEdit = true;
1
skipNext = true;
2
				startEditing();
2
		incrementCurrent();
3
				startingEdit = false;
3
		return element;
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.0
Clones locationClones are in different classes
Number of node comparisons7
  1. {Non-refactorable}
    Mapping Summary
    Number of mapped statements2
    Number of unmapped statements in the first code fragment1
    Number of unmapped statements in the second code fragment1
    Time elapsed for statement mapping (ms)0.0
    Clone typeType 2
    Mapped Statements
    ID Statement ID Statement
    3
    startingEdit = true;
    3
    startingEdit = true;
    1
    skipNext = true;
    Differences
    Expression1Expression2Difference
    startingEditskipNextVARIABLE_NAME_MISMATCH
    Preondition Violations
    Expression startingEdit is a field being modified, and thus it cannot be parameterized
    Expression skipNext is a field being modified, and thus it cannot be parameterized
    1
    skipNext = true;
    4
    startEditing();
    4
    startEditing();
    2
    incrementCurrent();
    Differences
    Expression1Expression2Difference
    startEditingincrementCurrentMETHOD_INVOCATION_NAME_MISMATCH
    Preondition Violations
    Expression startEditing() cannot be parameterized, because it has dependencies to/from statements that will be extracted
    • Inline private method startEditing
    Expression incrementCurrent() cannot be parameterized, because it has dependencies to/from statements that will be extracted
    Expression startEditing() is a void method call, and thus it cannot be parameterized
    Expression incrementCurrent() is a void method call, and thus it cannot be parameterized
    2
    incrementCurrent();
                                        
    3
    return element;
    Preondition Violations
    Unmatched return element;
    3
    return element;
    5
    startingEdit = false;
    5
    startingEdit = false;
    Preondition Violations
    Unmatched statement startingEdit=false; cannot be moved before the extracted code, because it has control dependencies from statements that will be extracted
                                                
    Precondition Violations (9)
    Row Violation
    1Expression startingEdit is a field being modified, and thus it cannot be parameterized
    2Expression skipNext is a field being modified, and thus it cannot be parameterized
    3Expression startEditing() cannot be parameterized, because it has dependencies to/from statements that will be extracted
    4Expression incrementCurrent() cannot be parameterized, because it has dependencies to/from statements that will be extracted
    5Expression startEditing() is a void method call, and thus it cannot be parameterized
    6Expression incrementCurrent() is a void method call, and thus it cannot be parameterized
    7Unmatched return element;
    8Unmatched statement startingEdit=false; cannot be moved before the extracted code, because it has control dependencies from statements that will be extracted
    9The refactoring of the clones is infeasible, because classes org.apache.jmeter.testbeans.gui.ComboStringEditor and org.apache.jmeter.control.InterleaveControl do not have a common superclass