| org.apache.ojb.broker.metadata.FieldType
FieldType | public interface FieldType extends Serializable(Code) | | OJB implements the mapping conventions for JDBC as specified by the JDBC 3.0 specification and
this class representing the jdbc java types of the sql types mappings - e.g.
VARCHAR --> String, NUMERIC --> BigDecimal
(see JDBC 3.0 specification Appendix B, Data Type Conversion Tables).
We differ two types of fields, immutable (like Integer, Long, String, ...) and mutable
(like Date, byte[], most SQL3 datatypes, ...).
version: $Id: FieldType.java,v 1.1.2.2 2005/12/21 22:26:10 tomdz Exp $ |
Method Summary | |
public Object | copy(Object fieldValue) Returns a copy of the specified persistent class field (e.g. | public boolean | equals(Object firstValue, Object secondValue) Returns true if the field value hasn't changed.
Parameters: firstValue - A field value object. Parameters: secondValue - A field value object. | public int | getSqlType() Returns the sql
java.sql.Types of this field. | public boolean | isMutable() Returns true if the field type is mutable, e.g. | public void | setSqlType(JdbcType jdbcType) Dets the associated sql field type of this field. |
copy | public Object copy(Object fieldValue)(Code) | | Returns a copy of the specified persistent class field (e.g. Long, Integer,...).
NOTE: The specified field value
Parameters: fieldValue - The field to copy. A copy of the field or the same instance if copying is not possible. Depends onthe implementation. |
equals | public boolean equals(Object firstValue, Object secondValue)(Code) | | Returns true if the field value hasn't changed.
Parameters: firstValue - A field value object. Parameters: secondValue - A field value object. true if the field value hasn't changed. |
isMutable | public boolean isMutable()(Code) | | Returns true if the field type is mutable, e.g. a jdbc BLOB field or
jdbc TIMESTAMP field.
|
|
|