File path: /emf-2.4.1/src/org/eclipse/emf/mapping/ecore2xml/impl/XMLInfoImpl.java | File path: /emf-2.4.1/src/org/eclipse/emf/mapping/ecore2xml/impl/XMLInfoImpl.java | |||
Method name: void setName(String)
|
Method name: void setXMLRepresentation(int)
|
|||
Number of AST nodes: 4 | Number of AST nodes: 4 | |||
1 | String oldName = delegateXMLInfo.getName();↵ | 1 | int oldXMLRepresentation = delegateXMLInfo.getXMLRepresentation();↵ | |
2 | delegateXMLInfo.setName(newName);↵ | 2 | delegateXMLInfo.setXMLRepresentation(newXMLRepresentation);↵ | |
3 | if (eNotificationRequired())↵ | 3 | if (eNotificationRequired())↵ | |
4 | eNotify(new ENotificationImpl(this, Notification.SET, Ecore2XMLPackage.XML_INFO__NAME, oldName, newName)); | 4 | eNotify(new ENotificationImpl(this, Notification.SET, Ecore2XMLPackage.XML_INFO__XML_REPRESENTATION, oldXMLRepresentation, newXMLRepresentation)); | |
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 | 8 |
Number of mapped statements | 2 |
Number of unmapped statements in the first code fragment | 2 |
Number of unmapped statements in the second code fragment | 2 |
Time elapsed for statement mapping (ms) | 0.7 |
Clone type | Type 2 |
ID | Statement | ID | Statement | ||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 1 | int oldXMLRepresentation = delegateXMLInfo.getXMLRepresentation(); | |||||||||||||||||||
1 | String oldName = delegateXMLInfo.getName(); | | |||||||||||||||||||
| 2 | delegateXMLInfo.setXMLRepresentation(newXMLRepresentation); | |||||||||||||||||||
2 | delegateXMLInfo.setName(newName); | | |||||||||||||||||||
3 | if (eNotificationRequired()) | 3 | if (eNotificationRequired()) | ||||||||||||||||||
4 | eNotify(new ENotificationImpl(this, Notification.SET, Ecore2XMLPackage.XML_INFO__NAME, oldName, newName)); |
| 4 | eNotify(new ENotificationImpl(this, Notification.SET, Ecore2XMLPackage.XML_INFO__XML_REPRESENTATION, oldXMLRepresentation, newXMLRepresentation)); |
Row | Violation |
---|---|
1 | Type java.lang.String of variable oldName does not match with type int of variable oldXMLRepresentation |