if (!(commandList.get(i) instanceof AbstractCommand.NonDirtying)) { return true; }
if (fileExtension.equals(extension)) { return true; }
Clone fragments detected by clone detection tool
File path: /emf-2.4.1/src/org/eclipse/emf/common/command/BasicCommandStack.java File path: /emf-2.4.1/src/org/eclipse/emf/ecore/xmi/impl/RootXMLContentHandlerImpl.java
Method name: boolean isSaveNeeded() Method name: boolean canHandle(URI)
Number of AST nodes: 2 Number of AST nodes: 2
1
if (!(commandList.get(i) instanceof AbstractCommand.NonDirtying))
1
if (fileExtension.equals(extension))
2
        {
2
        
3
  {
3
          return true;
4
            return true;
4
        }
5
          }
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 comparisons5
  1. {Non-refactorable}
    Mapping Summary
    Number of mapped statements2
    Number of unmapped statements in the first code fragment0
    Number of unmapped statements in the second code fragment0
    Time elapsed for statement mapping (ms)1.8
    Clone typeType 2
    Mapped Statements
    ID Statement ID Statement
    8
    if (!(commandList.get(i) instanceof AbstractCommand.NonDirtying))
    8
    if (!(commandList.get(i) instanceof AbstractCommand.NonDirtying))
    6
    if (fileExtension.equals(extension))
    Differences
    Expression1Expression2Difference
    !(commandList.get(i) instanceof AbstractCommand.NonDirtying)fileExtension.equals(extension)TYPE_COMPATIBLE_REPLACEMENT
    6
    if (fileExtension.equals(extension))
    9
    return true;
    9
    return true;
    7
    return true;
    Preondition Violations
    Conditional return true;
    Conditional return true;
    7
    return true;
    Precondition Violations (2)
    Row Violation
    1Conditional return true;
    2Conditional return true;