/** * creates a database table (which can also be a database view) * if the <name>id</name> contains schema than the relation is added * to the lookup table (see getDatabaseRelation and getRelation) with * both the fully qualified id and the table name only id * * @param id * @return */ public DatabaseRelationDefinition createDatabaseRelation(RelationID id) { if (!isStillMutable) { throw new IllegalStateException("Too late, cannot create a DB relation"); } DatabaseRelationDefinition table = new DatabaseRelationDefinition(id, typeMapper); add(table, tables); add(table, relations); listOfTables.add(table); return table; }
/** * creates a database table (which can also be a database view) * if the <name>id</name> contains schema than the relation is added * to the lookup table (see getDatabaseRelation and getRelation) with * both the fully qualified id and the table name only id * * @param id * @return */ public DatabaseRelationDefinition createDatabaseRelation(RelationID id) { if (!isStillMutable) { throw new IllegalStateException("Too late, cannot create a DB relation"); } DatabaseRelationDefinition table = new DatabaseRelationDefinition(id); add(table, tables); add(table, relations); listOfTables.add(table); return table; }