KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > hibernate > persister > entity > BasicEntityPropertyMapping


1 //$Id: BasicEntityPropertyMapping.java,v 1.4 2005/07/21 01:11:52 oneovthafew Exp $
2
package org.hibernate.persister.entity;
3
4 import org.hibernate.QueryException;
5 import org.hibernate.type.Type;
6
7 /**
8  * @author Gavin King
9  */

10 public class BasicEntityPropertyMapping extends AbstractPropertyMapping {
11
12     private final BasicEntityPersister persister;
13
14     public BasicEntityPropertyMapping(BasicEntityPersister persister) {
15         this.persister = persister;
16     }
17     
18     public String JavaDoc[] getIdentifierColumnNames() {
19         return persister.getIdentifierColumnNames();
20     }
21
22     protected String JavaDoc getEntityName() {
23         return persister.getEntityName();
24     }
25
26     public Type getType() {
27         return persister.getType();
28     }
29
30     public String JavaDoc[] toColumns(final String JavaDoc alias, final String JavaDoc propertyName) throws QueryException {
31         return super.toColumns(
32                 persister.generateTableAlias( alias, persister.getSubclassPropertyTableNumber(propertyName) ),
33                 propertyName
34             );
35     }
36     
37     
38 }
39
Popular Tags