File path: /emf-2.4.1/src/org/eclipse/emf/mapping/domain/PluginAdapterFactoryMappingDomain.java | File path: /emf-2.4.1/src/org/eclipse/emf/mapping/domain/PluginAdapterFactoryMappingDomain.java | |||
Method name: void initializeFromPlugin(String)
|
Method name: void initializeFromPlugin(String)
|
|||
Number of AST nodes: 8 | Number of AST nodes: 8 | |||
1 | if (topLabelCaseAll.length > 0) ↵ | 1 | if (bottomLabelCaseAll.length > 0) ↵ | |
2 | {↵ | 2 | {↵ | |
3 | String labelCase = topLabelCaseAll[0].getAttribute("value");↵ | 3 | String labelCase = bottomLabelCaseAll[0].getAttribute("value");↵ | |
4 | if (labelCase.equalsIgnoreCase("upper")) ↵ | 4 | if (labelCase.equalsIgnoreCase("upper")) ↵ | |
5 | {↵ | 5 | {↵ | |
6 | topLabelCase = LABEL_UPPER;↵ | 6 | bottomLabelCase = LABEL_UPPER;↵ | |
7 | }↵ | 7 | }↵ | |
8 | else if (labelCase.equalsIgnoreCase("lower")) ↵ | 8 | else if (labelCase.equalsIgnoreCase("lower")) ↵ | |
9 | {↵ | 9 | {↵ | |
10 | topLabelCase = LABEL_LOWER;↵ | 10 | bottomLabelCase = LABEL_LOWER;↵ | |
11 | }↵ | 11 | }↵ | |
12 | else if (labelCase.equalsIgnoreCase("mixed")) ↵ | 12 | else if (labelCase.equalsIgnoreCase("mixed")) ↵ | |
13 | {↵ | 13 | {↵ | |
14 | topLabelCase = LABEL_MIXED;↵ | 14 | bottomLabelCase = LABEL_MIXED;↵ | |
15 | }↵ | 15 | }↵ | |
16 | } | 16 |
| |
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.8 |
Clones location | Clones are in the same method |
Number of node comparisons | 33 |
Number of mapped statements | 8 |
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.4 |
Clone type | Type 2 |
ID | Statement | ID | Statement | |||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
28 | if (topLabelCaseAll.length > 0) |
| 37 | if (bottomLabelCaseAll.length > 0) | ||||||||||||
29 | String labelCase = topLabelCaseAll[0].getAttribute("value"); |
| 38 | String labelCase = bottomLabelCaseAll[0].getAttribute("value"); | ||||||||||||
30 | if (labelCase.equalsIgnoreCase("upper")) | 39 | if (labelCase.equalsIgnoreCase("upper")) | |||||||||||||
31 | topLabelCase = LABEL_UPPER; |
| 40 | bottomLabelCase = LABEL_UPPER; | ||||||||||||
32 | else if (labelCase.equalsIgnoreCase("lower")) | 41 | else if (labelCase.equalsIgnoreCase("lower")) | |||||||||||||
33 | topLabelCase = LABEL_LOWER; |
| 42 | bottomLabelCase = LABEL_LOWER; | ||||||||||||
34 | else if (labelCase.equalsIgnoreCase("mixed")) | 43 | else if (labelCase.equalsIgnoreCase("mixed")) | |||||||||||||
35 | topLabelCase = LABEL_MIXED; |
| 44 | bottomLabelCase = LABEL_MIXED; |
Row | Violation |
---|---|
1 | Expression topLabelCase is a field being modified, and thus it cannot be parameterized |
2 | Expression bottomLabelCase is a field being modified, and thus it cannot be parameterized |
3 | Expression topLabelCase is a field being modified, and thus it cannot be parameterized |
4 | Expression bottomLabelCase is a field being modified, and thus it cannot be parameterized |
5 | Expression topLabelCase is a field being modified, and thus it cannot be parameterized |
6 | Expression bottomLabelCase is a field being modified, and thus it cannot be parameterized |