org.jboss.ejb.plugins.cmp.jdbc
Class JDBCTypeComplex

java.lang.Object
  extended by org.jboss.ejb.plugins.cmp.jdbc.JDBCTypeComplex
All Implemented Interfaces:
JDBCType

public final class JDBCTypeComplex
extends Object
implements JDBCType

JDBCTypeComplex provides the mapping between a Java Bean (not an EJB) and a set of columns. This class has a flattened view of the Java Bean, which may contain other Java Beans. This class simply treats the bean as a set of properties, which may be in the a.b.c style. The details of how this mapping is performed can be found in JDBCTypeFactory. This class holds a description of the columns and the properties that map to the columns. Additionally, this class knows how to extract a column value from the Java Bean and how to set a column value info the Java Bean. See JDBCTypeComplexProperty for details on how this is done.

Version:
$Revision: 81030 $
Author:
Dain Sundstrom

Constructor Summary
JDBCTypeComplex(JDBCTypeComplexProperty[] properties, Class fieldType)
           
 
Method Summary
 boolean[] getAutoIncrement()
           
 String[] getColumnNames()
           
 Object getColumnValue(int index, Object value)
           
 Class[] getJavaTypes()
           
 int[] getJDBCTypes()
           
 boolean[] getNotNull()
           
 JDBCParameterSetter[] getParameterSetter()
           
 JDBCTypeComplexProperty[] getProperties()
           
 JDBCTypeComplexProperty getProperty(String propertyName)
           
 JDBCResultSetReader[] getResultSetReaders()
           
 String[] getSQLTypes()
           
 boolean hasMapper()
           
 boolean isSearchable()
           
 Object setColumnValue(int index, Object value, Object columnValue)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JDBCTypeComplex

public JDBCTypeComplex(JDBCTypeComplexProperty[] properties,
                       Class fieldType)
Method Detail

getColumnNames

public String[] getColumnNames()
Specified by:
getColumnNames in interface JDBCType

getJavaTypes

public Class[] getJavaTypes()
Specified by:
getJavaTypes in interface JDBCType

getJDBCTypes

public int[] getJDBCTypes()
Specified by:
getJDBCTypes in interface JDBCType

getSQLTypes

public String[] getSQLTypes()
Specified by:
getSQLTypes in interface JDBCType

getNotNull

public boolean[] getNotNull()
Specified by:
getNotNull in interface JDBCType

getAutoIncrement

public boolean[] getAutoIncrement()
Specified by:
getAutoIncrement in interface JDBCType

getColumnValue

public Object getColumnValue(int index,
                             Object value)
Specified by:
getColumnValue in interface JDBCType

setColumnValue

public Object setColumnValue(int index,
                             Object value,
                             Object columnValue)
Specified by:
setColumnValue in interface JDBCType

hasMapper

public boolean hasMapper()
Specified by:
hasMapper in interface JDBCType

isSearchable

public boolean isSearchable()
Specified by:
isSearchable in interface JDBCType

getResultSetReaders

public JDBCResultSetReader[] getResultSetReaders()
Specified by:
getResultSetReaders in interface JDBCType

getParameterSetter

public JDBCParameterSetter[] getParameterSetter()
Specified by:
getParameterSetter in interface JDBCType

getProperties

public JDBCTypeComplexProperty[] getProperties()

getProperty

public JDBCTypeComplexProperty getProperty(String propertyName)


Copyright © 2009 JBoss, a division of Red Hat, Inc.. All Rights Reserved.