File path: /hibernate-distribution-3.3.2.GA/project/core/src/main/java/org/hibernate/tuple/entity/Dom4jEntityTuplizer.java | File path: /hibernate-distribution-3.3.2.GA/project/core/src/main/java/org/hibernate/tuple/entity/DynamicMapEntityTuplizer.java | |||
Method name: PropertyAccessor buildPropertyAccessor(Property)
|
Method name: PropertyAccessor buildPropertyAccessor(Property)
|
|||
Number of AST nodes: 3 | Number of AST nodes: 3 | |||
1 | if ( mappedProperty.isBackRef() ) {↵ | 1 | if ( mappedProperty.isBackRef() ) {↵ | |
2 | return mappedProperty.getPropertyAccessor(null);↵ | 2 | return mappedProperty.getPropertyAccessor(null);↵ | |
3 | }↵ | 3 | }↵ | |
4 | else {↵ | 4 | else {↵ | |
5 | return PropertyAccessorFactory.getDom4jPropertyAccessor( ↵ | 5 | return PropertyAccessorFactory.getD↵ | |
6 | mappedProperty.getNodeName(), ↵ | |||
7 | mappedProperty.getType(),↵ | |||
8 | getEntityMetamodel().getSessionFactory()↵ | |||
9 | );↵ | 6 | ynamicMapPropertyAccessor();↵ | |
10 | } | 7 |
| |
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 in different classes having the same super class |
Number of node comparisons | 9 |
Number of mapped statements | 3 |
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 | if (mappedProperty.isBackRef()) | 1 | if (mappedProperty.isBackRef()) | ||||||||||||||
2 | return mappedProperty.getPropertyAccessor(null); | 2 | return mappedProperty.getPropertyAccessor(null); | ||||||||||||||
else | else | ||||||||||||||||
3 | return PropertyAccessorFactory.getDom4jPropertyAccessor(mappedProperty.getNodeName(), mappedProperty.getType(), getEntityMetamodel().getSessionFactory()); |
| 3 | return PropertyAccessorFactory.getDynamicMapPropertyAccessor(); |
Row | Violation |
---|