StringBuffer newString = new StringBuffer(); int lastIndex = 0; int newIndex = 0;
StringBuffer newString = new StringBuffer(); int lastIndex = 0; int newIndex = 0;
Clone fragments detected by clone detection tool
File path: /emf-2.4.1/src/org/eclipse/emf/mapping/domain/AdapterFactoryMappingDomain.java File path: /emf-2.4.1/src/org/eclipse/emf/mapping/domain/AdapterFactoryMappingDomain.java
Method name: String convertCase(String, int, int, char) Method name: String convertSeparator(String, char, char, int)
Number of AST nodes: 3 Number of AST nodes: 3
1
StringBuffer newString = new StringBuffer();
1
StringBuffer newString = new StringBuffer();
2
        int lastIndex = 0;
2
      int lastIndex = 0;
3
        int newIndex = 0;
3
      int newIndex = 0;
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 declared in the same class
Number of node comparisons5
  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 fragment0
    Time elapsed for statement mapping (ms)0.0
    Clone typeType 1
    Mapped Statements
    ID Statement ID Statement
    9
    StringBuffer newString = new StringBuffer();
    6
    StringBuffer newString = new StringBuffer();
    10
    int lastIndex = 0;
    7
    int lastIndex = 0;
    11
    int newIndex = 0;
    8
    int newIndex = 0;
    Precondition Violations (1)
    Row Violation
    1Clone fragment #1 returns variables lastIndex, newIndex, newString , while Clone fragment #2 returns variables lastIndex, newIndex, newString