public boolean onSave(Object entity, Serializable id, Object[] state,
String[] propertyNames, Type[] types) throws CallbackException {
if ( entity instanceof Document ) {
state[3] = state[2] = Calendar.getInstance();
return true;
}
else {
return false;
public boolean onSave(
Object entity, Serializable id, Object[] state,
String[] propertyNames, Type[] types
) throws CallbackException {
if ( entity instanceof Document ) {
state[4] = state[3] = Calendar.getInstance();
return true;
}
else {
return false;
Clone fragments detected by clone detection tool
File path: /hibernate-distribution-3.3.2.GA/project/testsuite/src/test/java/org/hibernate/test/interfaceproxy/DocumentInterceptor.java
|
|
File path: /hibernate-distribution-3.3.2.GA/project/testsuite/src/test/java/org/hibernate/test/mixed/DocumentInterceptor.java
|
Method name:
|
|
Method name:
|
Number of AST nodes: 0
|
|
Number of AST nodes: 0
|
|
1 | public boolean onSave(↵ | | 1 | public boolean onSave(↵
|
2 | Object entity, Serializable id, Object[] state,↵ | | 2 | Object entity, Serializable id, Object[] state,↵
|
3 | String[] propertyNames, Type[] types↵ | | 3 | String[] propertyNames, Type[] types↵
|
4 | ) throws CallbackException {↵ | | 4 | ) throws CallbackException {↵
|
5 | if ( entity instanceof Document ) {↵ | | 5 | if ( entity instanceof Document ) {↵
|
6 | state[3] = state[2] = Calendar.getInstance();↵ | | 6 | state[4] = state[3] = Calendar.getInstance();↵
|
7 | return true;↵ | | 7 | return true;↵
|
8 | }↵ | | 8 | }↵
|
9 | else {↵ | | 9 | else {↵
|
10 | return false;↵ | | 10 | return false;↵
|
11 | | | 11 |
|
See real code fragment |
|
See real code fragment |
Summary
Number of common nesting structure subtrees | 0 |
Number of refactorable cases | 0 |
Number of non-refactorable cases | 0 |
Time elapsed for finding largest common nesting structure subtrees (ms) | 0.0 |
Clones location | |
Number of node comparisons | 0 |