File path: /emf-2.4.1/src/org/eclipse/emf/mapping/command/AddOverrideCommand.java | File path: /emf-2.4.1/src/org/eclipse/emf/mapping/command/AddOverrideCommand.java | |||
Method name: Collection> getResult()
|
Method name: Collection> getAffectedObjects()
|
|||
Number of AST nodes: 5 | Number of AST nodes: 5 | |||
1 | Collection<Object> result = new ArrayList<Object>();↵ | 1 | Collection<Object> result = new ArrayList<Object>();↵ | |
2 | result.addAll(addCommand.doGetResult());↵ | 2 | result.addAll(addCommand.doGetAffectedObjects());↵ | |
3 | if (mapCommand != null)↵ | 3 | if (mapCommand != null)↵ | |
4 | {↵ | 4 | {↵ | |
5 | result.addAll(mapCommand.getResult());↵ | 5 | result.addAll(mapCommand.getAffectedObjects());↵ | |
6 | }↵ | 6 | }↵ | |
7 | return result; | 7 |
| |
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 declared in the same class |
Number of node comparisons | 9 |
Number of mapped statements | 5 |
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.0 |
Clone type | Type 2 |
ID | Statement | ID | Statement | |||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
1 | Collection<Object> result = new ArrayList<Object>(); | 1 | Collection<Object> result = new ArrayList<Object>(); | |||||||||||||
2 | result.addAll(addCommand.doGetResult()); |
| 2 | result.addAll(addCommand.doGetAffectedObjects()); | ||||||||||||
3 | if (mapCommand != null) | 3 | if (mapCommand != null) | |||||||||||||
4 | result.addAll(mapCommand.getResult()); |
| 4 | result.addAll(mapCommand.getAffectedObjects()); | ||||||||||||
5 | return result; | 5 | return result; |
Row | Violation |
---|---|
1 | Expression mapCommand.getResult() cannot be parameterized, because it has dependencies to/from statements that will be extracted |
2 | Expression mapCommand.getAffectedObjects() cannot be parameterized, because it has dependencies to/from statements that will be extracted |