while ( iterator.hasNext() ) {
Property prop = (Property) iterator.next();
if ( prop.getName().equals( StringHelper.root(propertyName) ) ) {
return prop;
}
}
while ( itr.hasPrevious() ) {
AuxiliaryDatabaseObject object = (AuxiliaryDatabaseObject) itr.previous();
if ( object.appliesToDialect( dialect ) ) {
script.add( object.sqlDropString( dialect, defaultCatalog, defaultSchema ) );
}
}
Clone fragments detected by clone detection tool
File path: /hibernate-distribution-3.3.2.GA/project/core/src/main/java/org/hibernate/mapping/PersistentClass.java
|
|
File path: /hibernate-distribution-3.3.2.GA/project/core/src/main/java/org/hibernate/cfg/Configuration.java
|
Method name: Property getProperty(String, Iterator)
|
|
Method name: String[] generateDropSchemaScript(Dialect)
|
Number of AST nodes: 4
|
|
Number of AST nodes: 4
|
|
1 | while ( iterator.hasNext() ) {↵ | | 1 | while ( it↵
|
2 | Property prop = (Property) iterator.next();↵ | | |
|
3 | if ( prop.getName().equals( StringHelper.root(propertyName) ) ) {↵ | | |
|
4 | return prop↵ | | 2 | r.hasPrevious() ) {↵
|
| | | 3 | AuxiliaryDatabaseObject object = (AuxiliaryDatabaseObject) itr.previous();↵
|
| | | 4 | if ( object.appliesToDialect( dialect ) ) {↵
|
5 | ;↵ | | 5 | script.add( object.sqlDropString( dialect, defaultCatalog, defaultSchema ) );↵
|
6 | }↵ | | 6 | }↵
|
7 | } | | 7 | }
|
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.2 |
Clones location | Clones are in different classes |
Number of node comparisons | 1 |