## org.firebirdsql.gds.impl
Class AbstractIscStmtHandle

    java.lang.Object
      org.firebirdsql.gds.impl.AbstractIscStmtHandle

All Implemented Interfaces:
  IscStmtHandle

Direct Known Subclasses:
  isc_stmt_handle_impl, isc_stmt_handle_impl

    public abstract class AbstractIscStmtHandle

extends Object
implements IscStmtHandle

Abstract implementation of the `IscStmtHandle` interface.

Field Summary
`String` `statement`

Fields inherited from interface org.firebirdsql.gds.IscStmtHandle
`TYPE_COMMIT, TYPE_DDL, TYPE_DELETE, TYPE_EXEC_PROCEDURE, TYPE_GET_SEGMENT, TYPE_INSERT, TYPE_PUT_SEGMENT, TYPE_ROLLBACK, TYPE_SELECT, TYPE_SELECT_FOR_UPDATE, TYPE_SET_GENERATOR, TYPE_START_TRANS, TYPE_UNKNOWN, TYPE_UPDATE`

Constructor Summary
`AbstractIscStmtHandle()`

Method Summary
`abstract void` `clearRows()` Clear all rows that have been fetched for this statement.
`abstract int` `getDeleteCount()` Get the number of rows that were deleted by executing this statement.
`String` `getExecutionPlan()` Get the execution plan from the statement.
`abstract int` `getInsertCount()` Get the number of rows that were inserted by executing this statement.
`abstract byte[][][]` `getRows()` Get the rows retrieved by executing this statement.
`int` `getStatementType()` Get the statement type.
`abstract AbstractIscTrHandle` `getTransaction()` Get current transaction in which statement is currently executed.
`abstract int` `getUpdateCount()` Get the number of rows that were updated by executing this statement.
`abstract boolean` `hasOpenResultSet()` Retrieve whether this statement has an open `ResultSet`.
`abstract boolean` `isSingletonResult()` Retrieve whether this statement has singleton result set.
`abstract boolean` `isValid()` Retrieve whether or not this statement is valid.
`abstract void` `registerTransaction(AbstractIscTrHandle trHandle)` Register statement for the transaction.
`abstract void` `removeRows()` Remove all rows contained by this statement.
`void` `setExecutionPlan(String plan)`
`void` `setStatementType(int statementType)`
`abstract int` `size()` Get the number of rows contained in this statement.
`abstract void` `unregisterTransaction()` Unregister statement from the transaction.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Methods inherited from interface org.firebirdsql.gds.IscStmtHandle
`getInSqlda, getOutSqlda, isAllRowsFetched`

Field Detail

### statement

    public String statement

Constructor Detail

### AbstractIscStmtHandle

    public AbstractIscStmtHandle()

Method Detail

### clearRows

    public abstract void clearRows()

  Clear all rows that have been fetched for this statement. This method differs from `removeRows()` in that it only affects rows that have already been fetched.

  See Also:
    `removeRows()`

### getDeleteCount

    public abstract int getDeleteCount()

  Get the number of rows that were deleted by executing this statement.

  Returns:
    The number of deleted rows

### getInsertCount

    public abstract int getInsertCount()

  Get the number of rows that were inserted by executing this statement.

  Returns:
    The number of inserted rows

### getRows

    public abstract byte[][][] getRows()

  Get the rows retrieved by executing this statement.

  Returns:
    Array of rows retrieved

### getUpdateCount

    public abstract int getUpdateCount()

  Get the number of rows that were updated by executing this statement.

  Returns:
    The number of updated rows

### hasOpenResultSet

    public abstract boolean hasOpenResultSet()

  Retrieve whether this statement has an open `ResultSet`.

  Returns:
    `true` if this statement has an open `ResultSet`, false otherwise

### isSingletonResult

    public abstract boolean isSingletonResult()

  Retrieve whether this statement has singleton result set.

  Returns:
    `true` if result set has singleton result set.

### isValid

    public abstract boolean isValid()

  Retrieve whether or not this statement is valid.

  Returns:
    `true` if this is a valid statement, `false` otherwise

### size

    public abstract int size()

  Get the number of rows contained in this statement.

  Returns:
    The rowcount for this statement

### removeRows

    public abstract void removeRows()

  Remove all rows contained by this statement. This method differs from `clearRows()` in that it effectively clears all rows from this statement.

  See Also:
    `clearRows()`

### registerTransaction

    public abstract void registerTransaction(AbstractIscTrHandle trHandle)

  Register statement for the transaction. This method is used within the `GDS.iscDsqlExecXXX` methods to keep a reference on current transaction in which statement is executed.

  Parameters:
    `trHandle` - instance of `AbstractIscTrHandle`.

### getTransaction

    public abstract AbstractIscTrHandle getTransaction()

  Get current transaction in which statement is currently executed.

  Returns:
    instance of `AbstractIscTrHandle` or `null` if statement is not assigned to a transaction.

### unregisterTransaction

    public abstract void unregisterTransaction()

  Unregister statement from the transaction.

### getExecutionPlan

    public String getExecutionPlan()

  Description copied from interface: `IscStmtHandle`
  Get the execution plan from the statement.

  Specified by:
    `getExecutionPlan` in interface `IscStmtHandle`
  Returns:
    execution plan or `null` if the execution plan was not fetched from the server.

### setExecutionPlan

    public void setExecutionPlan(String plan)

### getStatementType

    public int getStatementType()

  Description copied from interface: `IscStmtHandle`
  Get the statement type.

  Specified by:
    `getStatementType` in interface `IscStmtHandle`
  Returns:
    one of the constants defined in this interface or `IscStmtHandle.TYPE_UNKNOWN` when no statement type was received from the server.

### setStatementType

    public void setStatementType(int statementType)

Copyright © 2001-2010. All Rights Reserved.