File path: /hibernate-distribution-3.3.2.GA/project/core/src/main/java/org/hibernate/bytecode/cglib/BytecodeProviderImpl.java | File path: /hibernate-distribution-3.3.2.GA/project/core/src/main/java/org/hibernate/bytecode/javassist/BytecodeProviderImpl.java | |||
Method name: ReflectionOptimizer getReflectionOptimizer(Class, String[], String[], Class[])
|
Method name: ReflectionOptimizer getReflectionOptimizer(Class, String[], String[], Class[])
|
|||
Number of AST nodes: 5 | Number of AST nodes: 5 | |||
1 | if ( !clazz.isInterface() && !Modifier.isAbstract( clazz.getModifiers() ) ) {↵ | 1 | if ( !clazz.isInterface() && !Modifier.isAbstract( clazz.getModifiers() ) ) {↵ | |
2 | if ( fastClass == null ) {↵ | 2 | if ( fastClass == null ) {↵ | |
3 | bulkBean = null;↵ | 3 | bulkAccessor = null;↵ | |
4 | }↵ | 4 | }↵ | |
5 | else {↵ | 5 | else {↵ | |
6 | //test out the optimizer:↵ | 6 | //test out the optimizer:↵ | |
7 | Object instance = fastClass.newInstance();↵ | 7 | Object instance = fastClass.newInstance();↵ | |
8 | bulkBean.setPropertyValues( instance, bulkBean.getPropertyValues( instance ) );↵ | 8 | bulkAccessor.setPropertyValues( instance, bulkAccessor.getPropertyValues( instance ) );↵ | |
9 | }↵ | 9 | }↵ | |
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.5 |
Clones location | Clones are in different classes |
Number of node comparisons | 18 |
Number of mapped statements | 4 |
Number of unmapped statements in the first code fragment | 1 |
Number of unmapped statements in the second code fragment | 1 |
Time elapsed for statement mapping (ms) | 1.6 |
Clone type | Type 2 |
ID | Statement | ID | Statement | ||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
6 | if (!clazz.isInterface() && !Modifier.isAbstract(clazz.getModifiers())) | 6 | if (!clazz.isInterface() && !Modifier.isAbstract(clazz.getModifiers())) | ||||||||||||||||||||||
7 | if (fastClass == null) |
| 7 | if (fastClass == null) | |||||||||||||||||||||
| 8 | bulkAccessor = null; | |||||||||||||||||||||||
8 | bulkBean = null; | | |||||||||||||||||||||||
else | else | ||||||||||||||||||||||||
9 | Object instance = fastClass.newInstance(); |
| 9 | Object instance = fastClass.newInstance(); | |||||||||||||||||||||
10 | bulkBean.setPropertyValues(instance, bulkBean.getPropertyValues(instance)); |
| 10 | bulkAccessor.setPropertyValues(instance, bulkAccessor.getPropertyValues(instance)); |
Row | Violation |
---|---|
1 | Type net.sf.cglib.reflect.FastClass of variable fastClass does not match with type org.hibernate.bytecode.javassist.FastClass of variable fastClass |
2 | Type net.sf.cglib.reflect.FastClass of variable fastClass does not match with type org.hibernate.bytecode.javassist.FastClass of variable fastClass |
3 | Type net.sf.cglib.beans.BulkBean of variable bulkBean does not match with type org.hibernate.bytecode.javassist.BulkAccessor of variable bulkAccessor |
4 | Type net.sf.cglib.beans.BulkBean of variable bulkBean does not match with type org.hibernate.bytecode.javassist.BulkAccessor of variable bulkAccessor |