if (getPname() != null) { return getPname(); } else { return getObjSelect(); }
if (getPname() != null) { return getPname(); } else { return getObjselect(); }
Clone fragments detected by clone detection tool
File path: /apache-ant-1.7.0/src/org/apache/tools/ant/taskdefs/optional/clearcase/CCUnlock.java File path: /apache-ant-1.7.0/src/org/apache/tools/ant/taskdefs/optional/clearcase/CCLock.java
Method name: String getOpType() Method name: String getOpType()
Number of AST nodes: 3 Number of AST nodes: 3
1
if (getPname() != null) {
1
if (getPname() != null) {
2
            return getPname();
2
            return getPname();
3
        } else {
3
        } else {
4
            return getObjSelect();
4
            return getObjselect();
5
        }
5
        }
Summary
Number of common nesting structure subtrees1
Number of refactorable cases1
Number of non-refactorable cases0
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 comparisons9
  1. {Refactorable}
    Mapping Summary
    Number of mapped statements3
    Number of unmapped statements in the first code fragment0
    Number of unmapped statements in the second code fragment0
    Time elapsed for statement mapping (ms)0.5
    Clone typeType 2
    Mapped Statements
    ID Statement ID Statement
    1
    if (getPname() != null)
    1
    if (getPname() != null)
    2
    return getPname();
    2
    return getPname();
    else
    else
    3
    return getObjSelect();
    3
    return getObjSelect();
    3
    return getObjselect();
    Differences
    Expression1Expression2Difference
    getObjSelectgetObjselectMETHOD_INVOCATION_NAME_MISMATCH
    3
    return getObjselect();
    Precondition Violations (0)
    Row Violation