borland Packages Class Hierarchy dx.dataset Package
java.util.EventListener +----com.borland.dx.dataset.CoerceFromListener
MethodsIf set, the CoerceFromListener interface is called by implementors of Resolvers to coerce data from the data type of the Column to the data type of the data source. It is used by QueryDataSet, ProcedureDataSet, QueryResolver, and ProcedureResolver components. This allows an application to coerce column values from one data type to another as the values are received from a data source such as a JDBC driver.
Data types are automatically converted during the resolving phase according to the table listed in Data type conversions during data resolving. If you set a column's dataType property, thereby over-riding the default JDBC-to-com.borland mapping, automatic data type coercion is done. The exception to the automatic type coercion is when converting to and from a String to any type other than String (and other conversions involving such differing data types). A VariantException is thrown in these cases.
To customize the coercion, or to prevent the VariantException from being thrown (in cases as described in the previous paragraph), wire the CoerceFromListener.coerceFromColumn(...) event.
void coerceFromColumn(StorageDataSet dataSet, Column column, Variant from, Variant to)Allows an application to control the coercion of a data value from a column in the DataSet to the data source.