borland Packages Class Hierarchy dx.dataset Package
java.util.EventListener +----com.borland.dx.dataset.CoerceToListener
Methods
If set, the CoerceToListener interface is called by implementors of Providers to coerce data from the data type of the data source to the data type of the Column component. It is used by QueryDataSet, ProcedureDataSet, QueryProvider and ProcedureProvider components. This allows an application to coerce column values from one data type to another as the values are sent to a data source, such as a JDBC driver.
Data types are automatically converted during the providing phase according to the table listed in Data type conversions during data providing. 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 data 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 noted in the previous paragraph, wire the CoerceToListener.coerceToColumn(...) event.
void coerceToColumn(StorageDataSet dataSet, Column column, Variant from, Variant to)Allows an application to control the coercion of a data value from the data source to a column value in dataSet.