Populates this
CachedRowSetImpl
object with data from the given
ResultSet
object. This method is an alternative to the method
execute
for filling the rowset with data. The method
populate
does not require that the properties needed by the method
execute
, such as the
command
property, be set. This is true because the method
populate
is given the
ResultSet
object from which to get data and thus does not need to use the properties required for setting up a connection and executing this
CachedRowSetImpl
object's command.
After populating this rowset with data, the method populate
sets the rowset's metadata and then sends a RowSetChangedEvent
object to all registered listeners prior to returning.
@param data the ResultSet
object containing the datato be read into this CachedRowSetImpl
object
@throws SQLException if an error occurs; or the max row setting isviolated while populating the RowSet
@see #execute