* object within this <code>CachedRowSet</code> is in auto-commit mode. */ public void rollback() throws SQLException; /** * Each <code>CachedRowSet</code> object's <code>SyncProvider</code> contains * a <code>Connection</code> object from the original <code>ResultSet</code> * or JDBC properties passed to it. * <p> * Undoes all changes made in the current transaction back to the last * <code>Savepoint</code> transaction marker. This method should be used only * when auto-commit mode has been disabled. * * @param s A <code>Savepoint</code> transaction marker * @throws SQLException if a database access error occurs or this Connection * object within this <code>CachedRowSet</code> is in auto-commit mode. */ public void rollback(Savepoint s) throws SQLException; /** * Causes the <code>CachedRowSet</code> object's <code>SyncProvider</code> * to commit the changes when <code>acceptChanges()</code> is called. If * set to false, the changes will <b>not</b> be committed until one of the * <code>CachedRowSet</code> interface transaction methods is called. * * @deprecated Because this field is final (it is part of an interface), * its value cannot be changed. * @see #commit * @see #rollback */ @Deprecated public static final boolean COMMIT_ON_ACCEPT_CHANGES = true; /** * Notifies registered listeners that a RowSet object in the given RowSetEvent * object has populated a number of additional rows. The <code>numRows</code> parameter * ensures that this event will only be fired every <code>numRow</code>. * <p> * The source of the event can be retrieved with the method event.getSource. * * @param event a <code>RowSetEvent</code> object that contains the * <code>RowSet</code> object that is the source of the events * @param numRows when populating, the number of rows interval on which the * <code>CachedRowSet</code> populated should fire; the default value * is zero; cannot be less than <code>fetchSize</code> or zero */ public void rowSetPopulated(RowSetEvent event, int numRows) throws SQLException; /** * Populates this <code>CachedRowSet</code> object with data from * the given <code>ResultSet</code> object. While related to the <code>populate(ResultSet)</code> * method, an additional parameter is provided to allow starting position within * the <code>ResultSet</code> from where to populate the CachedRowSet * instance. * <P> * This method can be used as an alternative to the <code>execute</code> method when an * application has a connection to an open <code>ResultSet</code> object. * Using the method <code>populate</code> can be more efficient than using * the version of the <code>execute</code> method that takes no parameters * because it does not open a new connection and re-execute this * <code>CachedRowSet</code> object's command. Using the <code>populate</code> * method is more a matter of convenience when compared to using the version * of <code>execute</code> that takes a <code>ResultSet</code> object. * * @param startRow the position in the <code>ResultSet</code> from where to start * populating the records in this <code>CachedRowSet</code> * @param rs the <code>ResultSet</code> object containing the data * to be read into this <code>CachedRowSet</code> object * @throws SQLException if a null <code>ResultSet</code> object is supplied * or this <code>CachedRowSet</code> object cannot * retrieve the associated <code>ResultSetMetaData</code> object * @see #execute * @see #populate(ResultSet) * @see java.sql.ResultSet * @see java.sql.ResultSetMetaData */ public void populate(ResultSet rs, int startRow) throws SQLException; /** * Sets the <code>CachedRowSet</code> object's page-size. A <code>CachedRowSet</code> * may be configured to populate itself in page-size sized batches of rows. When * either <code>populate()</code> or <code>execute()</code> are called, the * <code>CachedRowSet</code> fetches an additional page according to the * original SQL query used to populate the RowSet. * * @param size the page-size of the <code>CachedRowSet</code> * @throws SQLException if an error occurs setting the <code>CachedRowSet</code> * page size or if the page size is less than 0. */ public void setPageSize(int size) throws SQLException; /** * Returns the page-size for the <code>CachedRowSet</code> object * * @return an <code>int</code> page size */ public int getPageSize(); /** * Increments the current page of the <code>CachedRowSet</code>. This causes * the <code>CachedRowSet</code> implementation to fetch the next page-size * rows and populate the RowSet, if remaining rows remain within scope of the * original SQL query used to populated the RowSet. * * @return true if more pages exist; false if this is the last page * @throws SQLException if an error occurs fetching the next page, or if this * method is called prematurely before populate or execute. */ public boolean nextPage() throws SQLException; /** * Decrements the current page of the <code>CachedRowSet</code>. This causes * the <code>CachedRowSet</code> implementation to fetch the previous page-size * rows and populate the RowSet. The amount of rows returned in the previous * page must always remain within scope of the original SQL query used to * populate the RowSet. * * @return true if the previous page is successfully retrieved; false if this * is the first page. * @throws SQLException if an error occurs fetching the previous page, or if * this method is called prematurely before populate or execute. */ public boolean previousPage() throws SQLException; }Lines 1501–1625 of 1625. Previous lines
* object within this <code>CachedRowSet</code> is in auto-commit mode. */ public void rollback() throws SQLException; /** * Each <code>CachedRowSet</code> object's <code>SyncProvider</code> contains * a <code>Connection</code> object from the original <code>ResultSet</code> * or JDBC properties passed to it. * <p> * Undoes all changes made in the current transaction back to the last * <code>Savepoint</code> transaction marker. This method should be used only * when auto-commit mode has been disabled. * * @param s A <code>Savepoint</code> transaction marker * @throws SQLException if a database access error occurs or this Connection * object within this <code>CachedRowSet</code> is in auto-commit mode. */ public void rollback(Savepoint s) throws SQLException; /** * Causes the <code>CachedRowSet</code> object's <code>SyncProvider</code> * to commit the changes when <code>acceptChanges()</code> is called. If * set to false, the changes will <b>not</b> be committed until one of the * <code>CachedRowSet</code> interface transaction methods is called. * * @deprecated Because this field is final (it is part of an interface), * its value cannot be changed. * @see #commit * @see #rollback */ @Deprecated public static final boolean COMMIT_ON_ACCEPT_CHANGES = true; /** * Notifies registered listeners that a RowSet object in the given RowSetEvent * object has populated a number of additional rows. The <code>numRows</code> parameter * ensures that this event will only be fired every <code>numRow</code>. * <p> * The source of the event can be retrieved with the method event.getSource. * * @param event a <code>RowSetEvent</code> object that contains the * <code>RowSet</code> object that is the source of the events * @param numRows when populating, the number of rows interval on which the * <code>CachedRowSet</code> populated should fire; the default value * is zero; cannot be less than <code>fetchSize</code> or zero */ public void rowSetPopulated(RowSetEvent event, int numRows) throws SQLException; /** * Populates this <code>CachedRowSet</code> object with data from * the given <code>ResultSet</code> object. While related to the <code>populate(ResultSet)</code> * method, an additional parameter is provided to allow starting position within * the <code>ResultSet</code> from where to populate the CachedRowSet * instance. * <P> * This method can be used as an alternative to the <code>execute</code> method when an * application has a connection to an open <code>ResultSet</code> object. * Using the method <code>populate</code> can be more efficient than using * the version of the <code>execute</code> method that takes no parameters * because it does not open a new connection and re-execute this * <code>CachedRowSet</code> object's command. Using the <code>populate</code> * method is more a matter of convenience when compared to using the version * of <code>execute</code> that takes a <code>ResultSet</code> object. * * @param startRow the position in the <code>ResultSet</code> from where to start * populating the records in this <code>CachedRowSet</code> * @param rs the <code>ResultSet</code> object containing the data * to be read into this <code>CachedRowSet</code> object * @throws SQLException if a null <code>ResultSet</code> object is supplied * or this <code>CachedRowSet</code> object cannot * retrieve the associated <code>ResultSetMetaData</code> object * @see #execute * @see #populate(ResultSet) * @see java.sql.ResultSet * @see java.sql.ResultSetMetaData */ public void populate(ResultSet rs, int startRow) throws SQLException; /** * Sets the <code>CachedRowSet</code> object's page-size. A <code>CachedRowSet</code> * may be configured to populate itself in page-size sized batches of rows. When * either <code>populate()</code> or <code>execute()</code> are called, the * <code>CachedRowSet</code> fetches an additional page according to the * original SQL query used to populate the RowSet. * * @param size the page-size of the <code>CachedRowSet</code> * @throws SQLException if an error occurs setting the <code>CachedRowSet</code> * page size or if the page size is less than 0. */ public void setPageSize(int size) throws SQLException; /** * Returns the page-size for the <code>CachedRowSet</code> object * * @return an <code>int</code> page size */ public int getPageSize(); /** * Increments the current page of the <code>CachedRowSet</code>. This causes * the <code>CachedRowSet</code> implementation to fetch the next page-size * rows and populate the RowSet, if remaining rows remain within scope of the * original SQL query used to populated the RowSet. * * @return true if more pages exist; false if this is the last page * @throws SQLException if an error occurs fetching the next page, or if this * method is called prematurely before populate or execute. */ public boolean nextPage() throws SQLException; /** * Decrements the current page of the <code>CachedRowSet</code>. This causes * the <code>CachedRowSet</code> implementation to fetch the previous page-size * rows and populate the RowSet. The amount of rows returned in the previous * page must always remain within scope of the original SQL query used to * populate the RowSet. * * @return true if the previous page is successfully retrieved; false if this * is the first page. * @throws SQLException if an error occurs fetching the previous page, or if * this method is called prematurely before populate or execute. */ public boolean previousPage() throws SQLException; }