10196-3-6

case EcorePackage.ECLASSIFIER__DEFAULT_VALUE: return getDefaultValue(); case EcorePackage.ECLASSIFIER__INSTANCE_TYPE_NAME: return getInstanceTypeName(); case EcorePackage.ECLASSIFIER__EPACKAGE: if (resolve) return getEPackage(); return basicGetEPackage(); case EcorePackage.ECLASSIFIER__ETYPE_PARAMETERS: return getETypeParameters();
case EcorePackage.EGENERIC_TYPE__EUPPER_BOUND: return getEUpperBound(); case EcorePackage.EGENERIC_TYPE__ETYPE_ARGUMENTS: return getETypeArguments(); case EcorePackage.EGENERIC_TYPE__ERAW_TYPE: if (resolve) return getERawType(); return basicGetERawType(); case EcorePackage.EGENERIC_TYPE__ELOWER_BOUND: return getELowerBound();

Clone fragments detected by clone detection tool
File path: /emf-2.4.1/src/org/eclipse/emf/ecore/impl/EClassifierImpl.java |  | File path: /emf-2.4.1/src/org/eclipse/emf/ecore/impl/EGenericTypeImpl.java
Method name: `Object eGet(int, boolean, boolean)` |  | Method name: `Object eGet(int, boolean, boolean)`
Number of AST nodes: 10 |  | Number of AST nodes: 10

1

    case EcorePackage.ECLASSIFIER__DEFAULT_VALUE:↵

1

    case EcorePackage.EGENERIC_TYPE__EUPPER_BOUND:↵

2

            return getDefaultValue();↵

2

            return getEUpperBound();↵

3

          case EcorePackage.ECLASSIFIER__INSTANCE_TYPE_NAME:↵

3

          case EcorePackage.EGENERIC_TYPE__ETYPE_ARGUMENTS:↵

4

            return getInstanceTypeName();↵

4

            return getETypeArguments();↵

5

          case EcorePackage.ECLASSIFIER__EPACKAGE:↵

5

          case EcorePackage.EGENERIC_TYPE__ERAW_TYPE:↵

6

            if (resolve) return getEPackage();↵

6

            if (resolve) return getERawType();↵

7

            return basicGetEPackage();↵

7

            return basicGetERawType();↵

8

          case EcorePackage.ECLASSIFIER__ETYPE_PARAMETERS:↵

8

          case EcorePackage.EGENERIC_TYPE__ELOWER_BOUND:↵

9

            return getETypeParameters();

9

            return getELowerBound();

See real code fragment |  | See real code fragment

Summary
Number of common nesting structure subtrees | 1
Number of refactorable cases | 0
Number of non-refactorable cases | 1
Time elapsed for finding largest common nesting structure subtrees (ms) | 0.1
Clones location | Clones are in different classes having the same super class
Number of node comparisons | 51

1. {Non-refactorable}

   Mapping Summary
   Number of mapped statements | 5
   Number of unmapped statements in the first code fragment | 5
   Number of unmapped statements in the second code fragment | 5
   Time elapsed for statement mapping (ms) | 1.6
   Clone type | Type 2

   Mapped Statements
   ID | Statement |  | ID | Statement
   --- | --- | --- | --- | ---

   3 | return getEUpperBound();

   Preondition Violations
   Unmatched return getEUpperBound();

   3

       return getEUpperBound();

   5 | return getETypeArguments();

   Preondition Violations
   Unmatched return getETypeArguments();

   5

       return getETypeArguments();

   10

       case EcorePackage.ECLASSIFIER__DEFAULT_VALUE:

   10 | case EcorePackage.ECLASSIFIER__DEFAULT_VALUE:
   10 | case EcorePackage.EGENERIC_TYPE__ELOWER_BOUND:

   Differences
   Expression1 | Expression2 | Difference
   --- | --- | ---
   ECLASSIFIER__DEFAULT_VALUE | EGENERIC_TYPE__ELOWER_BOUND | VARIABLE_NAME_MISMATCH

   10

       case EcorePackage.EGENERIC_TYPE__ELOWER_BOUND:

   11

       return getDefaultValue();

   11 | return getDefaultValue();

   Preondition Violations
   Unmatched return getDefaultValue();

   12

       case EcorePackage.ECLASSIFIER__INSTANCE_TYPE_NAME:

   12 | case EcorePackage.ECLASSIFIER__INSTANCE_TYPE_NAME:
   6 | case EcorePackage.EGENERIC_TYPE__ERAW_TYPE:

   Differences
   Expression1 | Expression2 | Difference
   --- | --- | ---
   ECLASSIFIER__INSTANCE_TYPE_NAME | EGENERIC_TYPE__ERAW_TYPE | VARIABLE_NAME_MISMATCH

   6

       case EcorePackage.EGENERIC_TYPE__ERAW_TYPE:

   13

       return getInstanceTypeName();

   13 | return getInstanceTypeName();

   Preondition Violations
   Unmatched return getInstanceTypeName();

   14

       case EcorePackage.ECLASSIFIER__EPACKAGE:

   14 | case EcorePackage.ECLASSIFIER__EPACKAGE:
   4 | case EcorePackage.EGENERIC_TYPE__ETYPE_ARGUMENTS:

   Differences
   Expression1 | Expression2 | Difference
   --- | --- | ---
   ECLASSIFIER__EPACKAGE | EGENERIC_TYPE__ETYPE_ARGUMENTS | VARIABLE_NAME_MISMATCH

   4

       case EcorePackage.EGENERIC_TYPE__ETYPE_ARGUMENTS:

   15

       if (resolve)

   7

       if (resolve)

   8 | return getERawType();

   Preondition Violations
   Unmatched return getERawType();

   8

       return getERawType();

   16

       return getEPackage();

   16 | return getEPackage();

   Preondition Violations
   Unmatched return getEPackage();

   17

       return basicGetEPackage();

   17 | return basicGetEPackage();

   Preondition Violations
   Unmatched return basicGetEPackage();

   18

       case EcorePackage.ECLASSIFIER__ETYPE_PARAMETERS:

   18 | case EcorePackage.ECLASSIFIER__ETYPE_PARAMETERS:
   2 | case EcorePackage.EGENERIC_TYPE__EUPPER_BOUND:

   Differences
   Expression1 | Expression2 | Difference
   --- | --- | ---
   ECLASSIFIER__ETYPE_PARAMETERS | EGENERIC_TYPE__EUPPER_BOUND | VARIABLE_NAME_MISMATCH

   2

       case EcorePackage.EGENERIC_TYPE__EUPPER_BOUND:

   9 | return basicGetERawType();

   Preondition Violations
   Unmatched return basicGetERawType();

   9

       return basicGetERawType();

   11 | return getELowerBound();

   Preondition Violations
   Unmatched return getELowerBound();

   11

       return getELowerBound();

   19

       return getETypeParameters();

   19 | return getETypeParameters();

   Preondition Violations
   Unmatched return getETypeParameters();

   Precondition Violations (10)
   Row | Violation
   --- | ---
   1 | Unmatched return getEUpperBound();
   2 | Unmatched return getETypeArguments();
   3 | Unmatched return getDefaultValue();
   4 | Unmatched return getInstanceTypeName();
   5 | Unmatched return getERawType();
   6 | Unmatched return getEPackage();
   7 | Unmatched return basicGetEPackage();
   8 | Unmatched return basicGetERawType();
   9 | Unmatched return getELowerBound();
   10 | Unmatched return getETypeParameters();