org.jboss.ejb.plugins.cmp.jdbc.metadata
Class JDBCValuePropertyMetaData

java.lang.Object
  extended by org.jboss.ejb.plugins.cmp.jdbc.metadata.JDBCValuePropertyMetaData

public final class JDBCValuePropertyMetaData
extends Object

Imutable class which contains information about a single dependent value object property.

Version:
$Revision: 1.9.4.1 $
Author:
Dain Sundstrom

Constructor Summary
JDBCValuePropertyMetaData(Element element, Class classType)
          Constructs a value property metadata class with the data contained in the property xml element from a jbosscmp-jdbc xml file.
 
Method Summary
 String getColumnName()
          Gets the column name which this property will be persisted.
 Method getGetter()
          Gets the getter method of this property.
 int getJDBCType()
          Gets the jdbc type of this property.
 String getPropertyName()
          Gets the name of this property.
 Class getPropertyType()
          Gets the java class type of this property.
 Method getSetter()
          Gets the setter method of this property.
 String getSqlType()
          Gets the sql type of this mapping.
 boolean isNotNull()
          Should this field allow null values?
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JDBCValuePropertyMetaData

public JDBCValuePropertyMetaData(Element element,
                                 Class classType)
                          throws org.jboss.deployment.DeploymentException
Constructs a value property metadata class with the data contained in the property xml element from a jbosscmp-jdbc xml file.

Parameters:
element - the xml Element which contains the metadata about this property
classType - the java Class type of the value class on which this property is defined
Throws:
org.jboss.deployment.DeploymentException - if the xml element is not semantically correct
Method Detail

getPropertyName

public String getPropertyName()
Gets the name of this property. The name will always begin with a lower case letter and is a Java Beans property name. This is the base name of the getter and setter property.

Returns:
the name of this property

getPropertyType

public Class getPropertyType()
Gets the java class type of this property. The class the the return type of the getter and type of the sole argument of the setter.

Returns:
the java Class type of this property

getColumnName

public String getColumnName()
Gets the column name which this property will be persisted.

Returns:
the name of the column which this property will be persisted

getJDBCType

public int getJDBCType()
Gets the jdbc type of this property. The jdbc type is used to retrieve data from a result set and to set parameters in a prepared statement.

Returns:
the jdbc type of this property

getSqlType

public String getSqlType()
Gets the sql type of this mapping. The sql type is the sql column data type, and is used in CREATE TABLE statements.

Returns:
the sql type String of this mapping

isNotNull

public boolean isNotNull()
Should this field allow null values?

Returns:
true if this field will not allow a null value.

getGetter

public Method getGetter()
Gets the getter method of this property. The getter method is used to retrieve the value of this property from the value class.

Returns:
the Method which gets the value of this property

getSetter

public Method getSetter()
Gets the setter method of this property. The setter method is used to set the value of this property in the value class.

Returns:
the Method which sets the value of this property


Copyright © 2002 JBoss Group, LLC. All Rights Reserved.