File path: /emf-2.4.1/src/org/eclipse/emf/ecore/impl/EClassImpl.java | File path: /emf-2.4.1/src/org/eclipse/emf/ecore/impl/EClassImpl.java | |||
Method name: EList
|
Method name: EList
|
|||
Number of AST nodes: 4 | Number of AST nodes: 4 | |||
1 | if (computationInProgress.add(this))↵ | 1 | if (computationInProgress.add(this))↵ | |
2 | {↵ | 2 | {↵ | |
3 | for (EClass eSuperType : getESuperTypes())↵ | 3 | for (EClass eSuperType : getESuperTypes())↵ | |
4 | {↵ | 4 | {↵ | |
5 | result.addAll(eSuperType.getEAllAttributes());↵ | 5 | result.addAll(eSuperType.getEAllReferences());↵ | |
6 | }↵ | 6 | }↵ | |
7 | computationInProgress.remove(this);↵ | 7 | computationInProgress.remove(this);↵ | |
8 | } | 8 |
| |
See real code fragment | See real code fragment |
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.3 |
Clones location | Clones are declared in the same class |
Number of node comparisons | 9 |
Number of mapped statements | 4 |
Number of unmapped statements in the first code fragment | 0 |
Number of unmapped statements in the second code fragment | 0 |
Time elapsed for statement mapping (ms) | 1.7 |
Clone type | Type 2 |
ID | Statement | ID | Statement | |||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
6 | if (computationInProgress.add(this)) | 5 | if (computationInProgress.add(this)) | |||||||||||||||||||||
7 | for (EClass eSuperType : getESuperTypes()) | 6 | for (EClass eSuperType : getESuperTypes()) | |||||||||||||||||||||
8 | result.addAll(eSuperType.getEAllAttributes()); |
| 7 | result.addAll(eSuperType.getEAllReferences()); | ||||||||||||||||||||
9 | computationInProgress.remove(this); | 8 | computationInProgress.remove(this); |
Row | Violation |
---|---|
1 | Expression eSuperType.getEAllAttributes() cannot be parameterized, because it has dependencies to/from statements that will be extracted |
2 | Expression eSuperType.getEAllReferences() cannot be parameterized, because it has dependencies to/from statements that will be extracted |
3 | Type org.eclipse.emf.common.util.EList<org.eclipse.emf.ecore.EAttribute> of variable eSuperType.getEAllAttributes() does not match with type org.eclipse.emf.common.util.EList<org.eclipse.emf.ecore.EReference> of variable eSuperType.getEAllReferences() |
4 | Type org.eclipse.emf.common.util.BasicEList<org.eclipse.emf.ecore.EAttribute> of variable result does not match with type org.eclipse.emf.common.util.BasicEList<org.eclipse.emf.ecore.EReference> of variable result |