File path: /hibernate-distribution-3.3.2.GA/project/core/src/main/java/org/hibernate/criterion/Example.java
|
|
File path: /hibernate-distribution-3.3.2.GA/project/core/src/main/java/org/hibernate/criterion/Example.java
|
Method name: void addComponentTypedValues(String, Object, AbstractComponentType, List, Criteria, CriteriaQuery)
|
|
Method name: void appendComponentCondition(String, Object, AbstractComponentType, Criteria, CriteriaQuery, StringBuffer)
|
Number of AST nodes: 12
|
|
Number of AST nodes: 7
|
|
1 | if (component!=null) {↵ | | |
|
2 | String[] propertyNames = type.getPropertyNames();↵ | | 1 | String[] propertyNames = type.getPropertyNames();↵
|
3 | Type[] subtypes = type.getSubtypes();↵ | | 2 | ↵
|
4 | Object[] values = type.getPropertyValues( component, getEntityMode(criteria, criteriaQuery) );↵ | | 3 | Object[] values = type.getPropertyValues( component, getEntityMode(criteria, criteriaQuery) );↵
|
5 | ↵ | | 4 | Type[] subtypes = type.getSubtypes();↵
|
6 | for (int i=0; i<propertyNames.length; i++) {↵ | | 5 | for (int i=0; i<propertyNames.length; i++) {↵
|
7 | Object value = values[i];↵ | | 6 | ↵
|
8 | Type subtype = subtypes[i];↵ | | |
|
9 | String subpath = StringHelper.qualify( path, propertyNames[i] );↵ | | 7 | String subpath = StringHelper.qualify( path, propertyNames[i] );↵
|
10 | ↵ | | 8 | Object value = values[i];↵
|
11 | if ( isPropertyIncluded(value, subpath, subtype) ) {↵ | | 9 | if ( isPropertyIncluded( value, subpath, subtypes[i] ) ) {↵
|
12 | ↵ | | 10 | Type subtype = subtypes[i];↵
|
13 | if ( subtype.isComponentType() ) {↵ | | 11 | if ( subtype.isComponentType() ) {↵
|
14 | addComponentTypedValues(subpath, value, ↵ | | 12 | appendComponentCondition(↵
|
| | | 13 | subpath,↵
|
| | | 14 | value,↵
|
15 | (AbstractComponentType) subtype, list, ↵ | | 15 | (AbstractComponentType) subtype,↵
|
16 | criteria, criteriaQuery);↵ | | 16 | criteria,↵
|
17 | }↵ | | |
|
18 | else {↵ | | |
|
19 | addPropertyTypedValue(value, subtype, list);↵ | | |
|
20 | }↵ | | |
|
21 | }↵ | | |
|
22 | }↵ | | |
|
23 | } | | |
|
| | | 17 | criteriaQuery,↵
|
| | | 18 | buf↵
|
| | | 19 | );
|