Type type = persister.getSubclassPropertyType(i);
if ( type.isAssociationType() ) {
walkEntityAssociationTree(
(AssociationType) type,
persister,
i,
alias,
path,
persister.isSubclassPropertyNullable(i),
currentDepth
);
}
else if ( type.isComponentType() ) {
walkComponentTree(
(AbstractComponentType) type,
i,
0,
persister,
alias,
subPath( path, persister.getSubclassPropertyName(i) ),
currentDepth
);
}
if ( type.isComponentType() ) {
AbstractComponentType actype = (AbstractComponentType) type;
initComponentPropertyPaths( path, actype, columns, formulaTemplates, factory );
if ( actype.isEmbedded() ) {
initComponentPropertyPaths(
path==null ? null : StringHelper.qualifier(path),
actype,
columns,
formulaTemplates,
factory
);
}
}
else if ( type.isEntityType() ) {
initIdentifierPropertyPaths( path, (EntityType) type, columns, factory );
}
Clone fragments detected by clone detection tool
File path: /hibernate-distribution-3.3.2.GA/project/core/src/main/java/org/hibernate/loader/JoinWalker.java
|
|
File path: /hibernate-distribution-3.3.2.GA/project/core/src/main/java/org/hibernate/persister/entity/AbstractPropertyMapping.java
|
Method name: void walkEntityTree(OuterJoinLoadable, String, String, int)
|
|
Method name: void initPropertyPaths(String, Type, String[], String[], Mapping)
|
Number of AST nodes: 5
|
|
Number of AST nodes: 7
|
|
1 | Type type = persister.getSubclassPropertyType(i);↵ | | |
|
2 | if ( type.isAssociationType() ) {↵ | | 1 | if ( type.isComponentType() ) {↵
|
3 | walkEntityAssociationTree(↵ | | 2 | ↵
|
4 | (AssociationType) type,↵ | | 3 | AbstractComponentType actype = (AbstractComponentType) type;↵
|
5 | persister,↵ | | 4 | ↵
|
6 | i,↵ | | |
|
7 | alias,↵ | | |
|
8 | path,↵ | | |
|
9 | persister.isSubclassPropertyNullable(i),↵ | | |
|
10 | currentDepth↵ | | |
|
11 | );↵ | | |
|
12 | }↵ | | |
|
13 | else ↵ | | 5 | initComponentPropertyPaths( path, actype, columns, formulaTemplates, factory );↵
|
14 | if ( type.isComponentType() ) {↵ | | 6 | if ( actype.isEmbedded() ) {↵
|
15 | walkComponentTree(↵ | | 7 | initComponent↵
|
16 | (AbstractComponentType) type,↵ | | |
|
17 | i,↵ | | |
|
18 | 0,↵ | | |
|
19 | persister,↵ | | |
|
20 | alias,↵ | | |
|
21 | subPath( path, persister.getSubclassPropertyName(i) ),↵ | | |
|
22 | currentDepth↵ | | |
|
23 | ↵ | | 8 | PropertyPaths(↵
|
| | | 9 | path==null ? null : StringHelper.qualifier(path),↵
|
| | | 10 | actype,↵
|
| | | 11 | columns,↵
|
| | | 12 | formulaTemplates,↵
|
| | | 13 | factory↵
|
| | | 14 | );↵
|
| | | 15 | }↵
|
| | | 16 | }↵
|
| | | 17 | else if ( type.isEntityType() ) {↵
|
24 | );↵ | | 18 | initIdentifierPropertyPaths( path, (EntityType) type, columns, factory );↵
|
25 | } | | 19 | }
|
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 | 2 |