if ( ! ReflectHelper.isPublic( ctor ) ) {
try {
// found a ctor, but it was not publicly accessible so try to request accessibility
ctor.setAccessible( true );
}
catch ( SecurityException e ) {
ctor = null;
}
}
if ( transacted && wasAutoCommit ) {
try {
connection.setAutoCommit( true );
}
catch( Throwable ignore ) {
log.trace( "was unable to reset connection back to auto-commit" );
}
}
Clone fragments detected by clone detection tool
File path: /hibernate-distribution-3.3.2.GA/project/core/src/main/java/org/hibernate/tuple/entity/EntityTuplizerFactory.java
|
|
File path: /hibernate-distribution-3.3.2.GA/project/core/src/main/java/org/hibernate/engine/transaction/Isolater.java
|
Method name: Constructor getProperConstructor(Class)
|
|
Method name: void delegateWork(IsolatedWork, boolean)
|
Number of AST nodes: 3
|
|
Number of AST nodes: 3
|
|
1 | if ( ! ReflectHelper.isPublic( ctor ) ) {↵ | | 1 | if ( ↵
|
| | | 2 | transacted && wasAutoCommit ) {↵
|
2 | try {↵ | | 3 | try {↵
|
3 | // found a ctor, but it was not publicly accessible so try to request accessibility↵ | | 4 | ↵
|
4 | ctor.setAccessible( true );↵ | | 5 | connection.setAutoCommit( true );↵
|
5 | }↵ | | 6 | ↵
|
| | | 7 | }↵
|
6 | catch ( SecurityException e ) {↵ | | 8 | catch( ↵
|
7 | ctor = null↵ | | 9 | Throwable ignore ) {↵
|
8 | ;↵ | | 10 | log.trace( "was unable to reset connection back to auto-commit" );↵
|
9 | }↵ | | 11 | }↵
|
10 | } | | 12 | }
|
See real code fragment |
|
See real code fragment |
Summary
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.0 |
Clones location | Clones are in different classes |
Number of node comparisons | 0 |
-
{Non-refactorable}
Mapping Summary
Number of mapped statements | 0 |
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.0 |
Clone type | Unknown type |
Mapped Statements
ID |
Statement |
|
ID |
Statement |
Precondition Violations (0)
Row |
Violation |