IntegerProperty prop = (IntegerProperty) super.clone(); prop.value = value; return prop;
FunctionProperty prop = (FunctionProperty) super.clone(); prop.cacheValue = cacheValue; prop.testIteration = testIteration; prop.function = function; return prop;
Clone fragments detected by clone detection tool
File path: /jakarta-jmeter-2.3.2/src/org/apache/jmeter/testelement/property/IntegerProperty.java File path: /jakarta-jmeter-2.3.2/src/org/apache/jmeter/testelement/property/FunctionProperty.java
Method name: Object clone() Method name: Object clone()
Number of AST nodes: 3 Number of AST nodes: 5
1
IntegerProperty prop = (IntegerProperty) super.clone();
1
FunctionProperty prop = (FunctionProperty) super.clone();
2
		prop.value = value
2
		prop.cacheValue = cacheValue;
3
		prop.testIteration = testIteration;
3
;
4
		prop.function = function;
4
		return prop;
5
		return prop;
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 having the same super class
Number of node comparisons11
  1. {Non-refactorable}
    Mapping Summary
    Number of mapped statements3
    Number of unmapped statements in the first code fragment0
    Number of unmapped statements in the second code fragment2
    Time elapsed for statement mapping (ms)0.0
    Clone typeType 3
    Mapped Statements
    ID Statement ID Statement
    1
    IntegerProperty prop = (IntegerProperty)super.clone();
    1
    IntegerProperty prop = (IntegerProperty)super.clone();
    1
    FunctionProperty prop = (FunctionProperty)super.clone();
    Differences
    Expression1Expression2Difference
    org.apache.jmeter.testelement.property.IntegerPropertyorg.apache.jmeter.testelement.property.FunctionPropertySUBCLASS_TYPE_MISMATCH
    org.apache.jmeter.testelement.property.IntegerPropertyorg.apache.jmeter.testelement.property.FunctionPropertySUBCLASS_TYPE_MISMATCH
    org.apache.jmeter.testelement.property.IntegerPropertyorg.apache.jmeter.testelement.property.FunctionPropertySUBCLASS_TYPE_MISMATCH
    1
    FunctionProperty prop = (FunctionProperty)super.clone();
                                                                
    2
    prop.cacheValue = cacheValue;
    2
    prop.value = value;
    2
    prop.value = value;
    3
    prop.testIteration = testIteration;
    Differences
    Expression1Expression2Difference
    org.apache.jmeter.testelement.property.IntegerPropertyorg.apache.jmeter.testelement.property.FunctionPropertySUBCLASS_TYPE_MISMATCH
    valuetestIterationVARIABLE_NAME_MISMATCH
    valuetestIterationVARIABLE_NAME_MISMATCH
    Preondition Violations
    Expression prop.value cannot be parameterized, because it has dependencies to/from statements that will be extracted
    Expression prop.testIteration cannot be parameterized, because it has dependencies to/from statements that will be extracted
    3
    prop.testIteration = testIteration;
                                                        
    4
    prop.function = function;
    3
    return prop;
    3
    return prop;
    5
    return prop;
    Differences
    Expression1Expression2Difference
    org.apache.jmeter.testelement.property.IntegerPropertyorg.apache.jmeter.testelement.property.FunctionPropertySUBCLASS_TYPE_MISMATCH
    5
    return prop;
    Precondition Violations (3)
    Row Violation
    1Expression prop.value cannot be parameterized, because it has dependencies to/from statements that will be extracted
    2Expression prop.testIteration cannot be parameterized, because it has dependencies to/from statements that will be extracted
    3Clone fragment #1 returns variables , while Clone fragment #2 returns variables prop