File path: /hibernate-distribution-3.3.2.GA/project/core/src/main/java/org/hibernate/cfg/Mappings.java
|
|
File path: /hibernate-distribution-3.3.2.GA/project/core/src/main/java/org/hibernate/cfg/Mappings.java
|
Method name: Table addTable(String, String, String, String, boolean)
|
|
Method name: Table addDenormalizedTable(String, String, String, boolean, String, Table)
|
Number of AST nodes: 13
|
|
Number of AST nodes: 11
|
|
1 | String key = subselect==null ?↵ | | 1 | String key = subselect==null ?↵
|
2 | Table.qualify(catalog, schema, name) :↵ | | 2 | Table.qualify(catalog, schema, name) :↵
|
3 | subselect;↵ | | 3 | subselect;↵
|
4 | Table table = (Table) tables.get(key);↵ | | 4 | ↵
|
|
5 | if (table == null) {↵ | | |
|
6 | table = new Table(↵ | | 5 | if ( tables.containsKey(key) ) {↵
|
| | | 6 | throw new DuplicateMappingException("table", name);↵
|
| | | 7 | }↵
|
| | | 8 | ↵
|
7 | );↵ | | 9 | Table table = new DenormalizedTable(includedTable);↵
|
8 | table.setAbstract(isAbstract);↵ | | 10 | table.setAbstract(isAbstract);↵
|
9 | table.setName(name);↵ | | 11 | table.setName(name);↵
|
10 | table.setSchema(schema);↵ | | 12 | table.setSchema(schema);↵
|
11 | table.setCatalog(catalog);↵ | | 13 | table.setCatalog(catalog);↵
|
12 | table.setSubselect(subselect);↵ | | 14 | table.setSubselect(subselect);↵
|
13 | tables.put(key, table);↵ | | 15 | tables.put(key, table);↵
|
14 | }↵ | | |
|
15 | else {↵ | | |
|
16 | if (!isAbstract) table.setAbstract(false);↵ | | |
|
17 | }↵ | | |
|
|
18 | return table; | | 16 | return table;
|