if (el != null) { super.addTestElement(el); log.info("TestElement: " + el.getClass().getName()); }
if (null != sslmgr){ sslmgr.setContext(conn); // N.B. must be done after opening connection }
Clone fragments detected by clone detection tool
File path: /jakarta-jmeter-2.3.2/src/org/apache/jmeter/testelement/AbstractTable.java File path: /jakarta-jmeter-2.3.2/src/org/apache/jmeter/protocol/http/sampler/HTTPSampler.java
Method name: void addTestElement(TestElement) Method name: HttpURLConnection setupConnection(URL, String, HTTPSampleResult)
Number of AST nodes: 3 Number of AST nodes: 2
1
if (el != null) {
1
if (null != 
2
            super.addTestElement(el);
3
            log.info("TestElement: " + el.getClass().getName());
4
        
2
sslmgr){
3
				    sslmgr.setContext(conn); // N.B. must be done after opening connection
5
}
4
				}
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.1
Clones locationClones are in different classes having the same super class
Number of node comparisons6
  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 fragment0
    Time elapsed for statement mapping (ms)17.7
    Clone typeType 3
    Mapped Statements
    ID Statement ID Statement
    1
    if (el != null)
    1
    if (el != null)
    9
    if (null != sslmgr)
    Differences
    Expression1Expression2Difference
    elnullTYPE_COMPATIBLE_REPLACEMENT
    nullsslmgrTYPE_COMPATIBLE_REPLACEMENT
    9
    if (null != sslmgr)
    2
    super.addTestElement(el);
    2
    super.addTestElement(el);
    10
    sslmgr.setContext(conn);
    Differences
    Expression1Expression2Difference
    super.addTestElement(el)sslmgr.setContext(conn)TYPE_COMPATIBLE_REPLACEMENT
    Preondition Violations
    Expression super.addTestElement(el) is a void method call, and thus it cannot be parameterized
    Expression sslmgr.setContext(conn) is a void method call, and thus it cannot be parameterized
    10
    sslmgr.setContext(conn);
    3
    log.info("TestElement: " + el.getClass().getName());
                                                                                                                  
    Precondition Violations (2)
    Row Violation
    1Expression super.addTestElement(el) is a void method call, and thus it cannot be parameterized
    2Expression sslmgr.setContext(conn) is a void method call, and thus it cannot be parameterized