Package: groovy.sql

## [Java] Interface GroovyResultSet

- groovy.lang.GroovyObject

- All Superinterfaces:
    GroovyObject

      public interface GroovyResultSet
      extends GroovyObject, ResultSet

  Represents an extent of objects

- - Inherited fields
    Fields inherited from class | Fields
    --- | ---
    `interface ResultSet` | `FETCH_FORWARD, FETCH_REVERSE, FETCH_UNKNOWN, TYPE_FORWARD_ONLY, TYPE_SCROLL_INSENSITIVE, TYPE_SCROLL_SENSITIVE, CONCUR_READ_ONLY, CONCUR_UPDATABLE, HOLD_CURSORS_OVER_COMMIT, CLOSE_CURSORS_AT_COMMIT`

  - ### Methods Summary

    Methods
    Type Params | Return Type | Name and description
    --- | --- | ---
    `` | `public void` | `add(Map values)` Adds a new row to this result set
    `` | `public void` | `eachRow(Closure closure)` Call the closure once for each row in the result set.
    `` | `public Object` | `getAt(int index)` Supports integer-based subscript operators for accessing at numbered columns starting at zero.
    `` | `public Object` | `getAt(String columnName)` Gets the value of the designated column in the current row as an `Object`.
    `` | `public void` | `putAt(int index, Object newValue)` Supports integer based subscript operators for updating the values of numbered columns starting at zero.
    `` | `public void` | `putAt(String columnName, Object newValue)` Updates the designated column with an `Object` value.

  - ### Inherited Methods Summary

    Inherited Methods
    Methods inherited from class | Name
    --- | ---
    `interface GroovyObject` | `getMetaClass, getProperty, invokeMethod, setMetaClass, setProperty`
    `interface ResultSet` | `absolute, afterLast, beforeFirst, cancelRowUpdates, clearWarnings, close, deleteRow, findColumn, first, getArray, getArray, getAsciiStream, getAsciiStream, getBigDecimal, getBigDecimal, getBigDecimal, getBigDecimal, getBinaryStream, getBinaryStream, getBlob, getBlob, getBoolean, getBoolean, getByte, getByte, getBytes, getBytes, getCharacterStream, getCharacterStream, getClob, getClob, getConcurrency, getCursorName, getDate, getDate, getDate, getDate, getDouble, getDouble, getFetchDirection, getFetchSize, getFloat, getFloat, getHoldability, getInt, getInt, getLong, getLong, getMetaData, getNCharacterStream, getNCharacterStream, getNClob, getNClob, getNString, getNString, getObject, getObject, getObject, getObject, getObject, getObject, getRef, getRef, getRow, getRowId, getRowId, getSQLXML, getSQLXML, getShort, getShort, getStatement, getString, getString, getTime, getTime, getTime, getTime, getTimestamp, getTimestamp, getTimestamp, getTimestamp, getType, getURL, getURL, getUnicodeStream, getUnicodeStream, getWarnings, insertRow, isAfterLast, isBeforeFirst, isClosed, isFirst, isLast, isWrapperFor, last, moveToCurrentRow, moveToInsertRow, next, previous, refreshRow, relative, rowDeleted, rowInserted, rowUpdated, setFetchDirection, setFetchSize, unwrap, updateArray, updateArray, updateAsciiStream, updateAsciiStream, updateAsciiStream, updateAsciiStream, updateAsciiStream, updateAsciiStream, updateBigDecimal, updateBigDecimal, updateBinaryStream, updateBinaryStream, updateBinaryStream, updateBinaryStream, updateBinaryStream, updateBinaryStream, updateBlob, updateBlob, updateBlob, updateBlob, updateBlob, updateBlob, updateBoolean, updateBoolean, updateByte, updateByte, updateBytes, updateBytes, updateCharacterStream, updateCharacterStream, updateCharacterStream, updateCharacterStream, updateCharacterStream, updateCharacterStream, updateClob, updateClob, updateClob, updateClob, updateClob, updateClob, updateDate, updateDate, updateDouble, updateDouble, updateFloat, updateFloat, updateInt, updateInt, updateLong, updateLong, updateNCharacterStream, updateNCharacterStream, updateNCharacterStream, updateNCharacterStream, updateNClob, updateNClob, updateNClob, updateNClob, updateNClob, updateNClob, updateNString, updateNString, updateNull, updateNull, updateObject, updateObject, updateObject, updateObject, updateObject, updateObject, updateObject, updateObject, updateRef, updateRef, updateRow, updateRowId, updateRowId, updateSQLXML, updateSQLXML, updateShort, updateShort, updateString, updateString, updateTime, updateTime, updateTimestamp, updateTimestamp, wasNull`

- - ### Method Detail

    - #### public void add(Map values)

      Adds a new row to this result set

      throws:
        SQLException if a database error occurs
      Parameters:
        `values` - the new values to add

    - #### public void eachRow(Closure closure)

      Call the closure once for each row in the result set.

      throws:
        SQLException if a database error occurs
      Parameters:
        `closure` - the closure to call for each row

    - #### public Object getAt(int index)

      Supports integer-based subscript operators for accessing at numbered columns starting at zero. Negative indices are supported, they will count from the last column backwards.

      throws:
        SQLException if a database error occurs
      Parameters:
        `index` - is the number of the column to look at starting at 1
      Returns:
        the object for this index in the current result set

    - #### public Object getAt(String columnName)

      Gets the value of the designated column in the current row as an `Object`.

      throws:
        groovy.lang.MissingPropertyException if an SQLException happens while getting the object
      Parameters:
        `columnName` - the SQL name of the column
      Returns:
        the returned column value

    - #### public void putAt(int index, Object newValue)

      Supports integer based subscript operators for updating the values of numbered columns starting at zero. Negative indices are supported, they will count from the last column backwards.

      throws:
        SQLException if a database error occurs
      Parameters:
        `index` - is the number of the column to look at starting at 1
        `newValue` - the new value for this index

    - #### public void putAt(String columnName, Object newValue)

      Updates the designated column with an `Object` value.

      throws:
        groovy.lang.MissingPropertyException if an SQLException happens while setting the new value
      Parameters:
        `columnName` - the SQL name of the column
        `newValue` - the updated value