org.hibernatespatial.pojo
Class TypeMapper

java.lang.Object
  extended by org.hibernatespatial.pojo.TypeMapper

public class TypeMapper
extends Object

The TypeMapper maps a pair consisting of java.sql.Type, and a database type name to a CtClass (a representation of a java type used by the javassist class building tools) and to a Hibernate type (used when creating a mapping file).

Author:
Karel Maesen, Geovise BVBA (http://www.geovise.com/)

Field Summary
protected static org.slf4j.Logger logger
           
 
Constructor Summary
TypeMapper(String dbGeomType)
           
 
Method Summary
 void addTypeMapping(int sqlType, String hibernateType, javassist.CtClass ctClass)
           
 javassist.CtClass getCtClass(String dbType, int sqlType)
           
 String getHibernateType(String dbType, int sqlType)
           
 int[] getMappedSQLTypes()
           
 void removeTypeMapping(int sqlType)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

logger

protected static final org.slf4j.Logger logger
Constructor Detail

TypeMapper

public TypeMapper(String dbGeomType)
Method Detail

getCtClass

public javassist.CtClass getCtClass(String dbType,
                                    int sqlType)

getHibernateType

public String getHibernateType(String dbType,
                               int sqlType)
                        throws TypeNotFoundException
Throws:
TypeNotFoundException

getMappedSQLTypes

public int[] getMappedSQLTypes()

addTypeMapping

public void addTypeMapping(int sqlType,
                           String hibernateType,
                           javassist.CtClass ctClass)

removeTypeMapping

public void removeTypeMapping(int sqlType)


Copyright © 2011 hibernatespatial.org. All Rights Reserved.