File path: /emf-2.4.1/src/org/eclipse/emf/edit/provider/DelegatingWrapperItemProvider.java | File path: /emf-2.4.1/src/org/eclipse/emf/edit/provider/DelegatingWrapperItemProvider.java | |||
Method name: void setPropertyValue(Object, Object)
|
Method name: void resetPropertyValue(Object)
|
|||
Number of AST nodes: 6 | Number of AST nodes: 6 | |||
1 | boolean hasCommandOwner = commandOwner != null;↵ | 1 | boolean hasCommandOwner = commandOwner != null;↵ | |
2 | if (!hasCommandOwner)↵ | 2 | if (!hasCommandOwner)↵ | |
3 | {↵ | 3 | {↵ | |
4 | setCommandOwner(DelegatingWrapperItemProvider.this);↵ | 4 | setCommandOwner(DelegatingWrapperItemProvider.this);↵ | |
5 | }↵ | 5 | }↵ | |
6 | itemPropertyDescriptor.setPropertyValue(object, value);↵ | 6 | itemPropertyDescriptor.resetPropertyValue(object);↵ | |
7 | if (!hasCommandOwner)↵ | 7 | if (!hasCommandOwner)↵ | |
8 | {↵ | 8 | {↵ | |
9 | setCommandOwner(null);↵ | 9 | setCommandOwner(null);↵ | |
10 | } | 10 |
| |
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 | 17 |
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.8 |
Clone type | Type 2 |
ID | Statement | ID | Statement | ||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
1 | boolean hasCommandOwner = commandOwner != null; | 1 | boolean hasCommandOwner = commandOwner != null; | ||||||||||||||||||
2 | if (!hasCommandOwner) | 2 | if (!hasCommandOwner) | ||||||||||||||||||
3 | setCommandOwner(DelegatingWrapperItemProvider.this); | 3 | setCommandOwner(DelegatingWrapperItemProvider.this); | ||||||||||||||||||
4 | itemPropertyDescriptor.setPropertyValue(object, value); |
| 4 | itemPropertyDescriptor.resetPropertyValue(object); | |||||||||||||||||
5 | if (!hasCommandOwner) | 5 | if (!hasCommandOwner) | ||||||||||||||||||
6 | setCommandOwner(null); | 6 | setCommandOwner(null); |
Row | Violation |
---|---|
1 | Expression itemPropertyDescriptor.setPropertyValue(object,value) is a void method call, and thus it cannot be parameterized |
2 | Expression itemPropertyDescriptor.resetPropertyValue(object) is a void method call, and thus it cannot be parameterized |
3 | Expression itemPropertyDescriptor.setPropertyValue(object,value) is a void method call, and thus it cannot be parameterized |
4 | Expression itemPropertyDescriptor.resetPropertyValue(object) is a void method call, and thus it cannot be parameterized |