File path: /emf-2.4.1/src/org/eclipse/emf/importer/rose/parser/RoseNode.java | File path: /emf-2.4.1/src/org/eclipse/emf/importer/rose/parser/RoseNode.java | |||
Method name: int getXMLContentKind()
|
Method name: int getXMLFeatureKind()
|
|||
Number of AST nodes: 6 | Number of AST nodes: 6 | |||
1 | String attributeValue = getAttributeValue("Ecore", "xmlContentKind");↵ | 1 | String attributeValue = getAttributeValue("Ecore", "xmlFeatureKind");↵ | |
2 | if (attributeValue != null)↵ | 2 | if (attributeValue != null)↵ | |
3 | {↵ | 3 | {↵ | |
4 | Matcher matcher = CONTENT_VALUE_PATTERN.matcher(attributeValue);↵ | 4 | Matcher matcher = FEATURE_VALUE_PATTERN.matcher(attributeValue);↵ | |
5 | if (matcher.matches())↵ | 5 | if (matcher.matches())↵ | |
6 | {↵ | 6 | {↵ | |
7 | return Integer.parseInt(matcher.group(1));↵ | 7 | return Integer.parseInt(matcher.group(1));↵ | |
8 | }↵ | 8 | }↵ | |
9 | }↵ | 9 | }↵ | |
10 | return 0; | 10 |
| |
See real code fragment | See real code fragment |
Number of common nesting structure subtrees | 1 |
Number of refactorable cases | 1 |
Number of non-refactorable cases | 0 |
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 | 12 |
Number of mapped statements | 6 |
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) | 0.9 |
Clone type | Type 2 |
ID | Statement | ID | Statement | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
1 | String attributeValue = getAttributeValue("Ecore", "xmlContentKind"); |
| 1 | String attributeValue = getAttributeValue("Ecore", "xmlFeatureKind"); | ||||||||||
2 | if (attributeValue != null) | 2 | if (attributeValue != null) | |||||||||||
3 | Matcher matcher = CONTENT_VALUE_PATTERN.matcher(attributeValue); |
| 3 | Matcher matcher = FEATURE_VALUE_PATTERN.matcher(attributeValue); | ||||||||||
4 | if (matcher.matches()) | 4 | if (matcher.matches()) | |||||||||||
5 | return Integer.parseInt(matcher.group(1)); | 5 | return Integer.parseInt(matcher.group(1)); | |||||||||||
6 | return 0; | 6 | return 0; |
Row | Violation |
---|