File path: /emf-2.4.1/src/org/eclipse/emf/importer/ModelImporter.java | File path: /emf-2.4.1/src/org/eclipse/emf/mapping/ecore2xml/presentation/Ecore2XMLModelWizard.java | |||
Method name: List
|
Method name: Collection
|
|||
Number of AST nodes: 3 | Number of AST nodes: 4 | |||
1 | if (fileExtensions == null)↵ | 1 | if (initialObjectNames == null)↵ | |
2 | {↵ | 2 | {↵ | |
3 | fileExtensions = new ArrayList<String>();↵ | 3 | initialObjectNames = new ArrayList<String>();↵ | |
4 | }↵ | 4 | ↵ | |
5 | return fileExtension↵ | 5 | initialObjectNames.add(ecore2XMLPackage.getXMLMap().getName());↵ | |
6 | }↵ | |||
6 | s; | 7 | return initialObjectNames; | |
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.1 |
Clones location | Clones are in different classes |
Number of node comparisons | 7 |
Number of mapped statements | 3 |
Number of unmapped statements in the first code fragment | 0 |
Number of unmapped statements in the second code fragment | 1 |
Time elapsed for statement mapping (ms) | 0.6 |
Clone type | Type 3 |
ID | Statement | ID | Statement | |||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
1 | if (fileExtensions == null) |
| 1 | if (initialObjectNames == null) | ||||||||||||
2 | fileExtensions = new ArrayList<String>(); |
| 2 | initialObjectNames = new ArrayList<String>(); | ||||||||||||
| 3 | initialObjectNames.add(ecore2XMLPackage.getXMLMap().getName()); | ||||||||||||||
3 | return fileExtensions; |
| 4 | return initialObjectNames; |
Row | Violation |
---|---|
1 | Expression fileExtensions is a field being modified, and thus it cannot be parameterized |
2 | Expression initialObjectNames is a field being modified, and thus it cannot be parameterized |
3 | Expression fileExtensions cannot be parameterized, because it has dependencies to/from statements that will be extracted |
4 | Expression initialObjectNames cannot be parameterized, because it has dependencies to/from statements that will be extracted |