Class V16Statement

    • Constructor Detail

      • V16Statement

        public V16Statement​(FbWireDatabase database)
        Creates a new instance of V16Statement for the specified database.
        Parameters:
        database - FbWireDatabase implementation
    • Method Detail

      • sendExecute

        protected void sendExecute​(int operation,
                                   RowValue parameters)
                            throws java.io.IOException,
                                   java.sql.SQLException
        Description copied from class: V10Statement
        Sends the execute (for op_execute or op_execute2) to the database.
        Overrides:
        sendExecute in class V10Statement
        Parameters:
        operation - Operation (op_execute or op_execute2)
        parameters - Parameters
        Throws:
        java.io.IOException
        java.sql.SQLException
      • supportBatchUpdates

        public boolean supportBatchUpdates()
        Description copied from interface: FbStatement
        Reports whether this statement implementation supports server-side batch updates.
        Returns:
        true server-side batch updates supported, false if not supported (default implementation returns false)
      • createBatchParameterBuffer

        public BatchParameterBuffer createBatchParameterBuffer()
                                                        throws java.sql.SQLException
        Description copied from interface: FbStatement
        Creates a BatchParameterBuffer instance compatible with this protocol version.
        Returns:
        batch parameter buffer
        Throws:
        java.sql.SQLException - if this statement is closed, or a database access error occurs, or when the parameter buffer could not be created for other reasons
        java.sql.SQLFeatureNotSupportedException - when this statement implementation does not support batch updates
        See Also:
        FbStatement.supportBatchUpdates()
      • deferredBatchCreate

        public void deferredBatchCreate​(FbBatchConfig batchConfig,
                                        DeferredResponse<java.lang.Void> onResponse)
                                 throws java.sql.SQLException
        Description copied from interface: FbStatement
        Sends batch create with deferred response processing.

        Implementations that do not supported deferred or async response processing should call DeferredResponse.onResponse(Object) and - optionally - DeferredResponse.onException(Exception) synchronously. If the response is deferred, but the implementation is not capable of connecting the response back, it should call onResponse before method return, and any exceptions generated by deferred processing should then be thrown from the method that causes the response to be received.

        Parameters:
        batchConfig - batch configuration
        onResponse - deferred action to call when response is received
        Throws:
        java.sql.SQLException - for database access errors (I/O errors)
        java.sql.SQLFeatureNotSupportedException - when this statement implementation does not support batch updates
        See Also:
        FbStatement.supportBatchUpdates()
      • sendBatchCreate

        protected void sendBatchCreate​(FbBatchConfig batchConfig)
                                throws java.sql.SQLException,
                                       java.io.IOException
        Throws:
        java.sql.SQLException
        java.io.IOException
      • deferredBatchSend

        public void deferredBatchSend​(java.util.Collection<RowValue> rowValues,
                                      DeferredResponse<java.lang.Void> onResponse)
                               throws java.sql.SQLException
        Description copied from interface: FbStatement
        Sends batch data with deferred response processing.

        For implementations that do not supported deferred or async response processing, see FbStatement.deferredBatchCreate(FbBatchConfig, DeferredResponse) for expected behaviour.

        Parameters:
        rowValues - collection of row values
        onResponse - deferred action to call when response is received
        Throws:
        java.sql.SQLException - for database access errors (I/O errors)
        java.sql.SQLFeatureNotSupportedException - when this statement implementation does not support batch updates
        See Also:
        FbStatement.supportBatchUpdates()
      • sendBatchMsg

        protected void sendBatchMsg​(java.util.Collection<RowValue> rowValues)
                             throws java.sql.SQLException,
                                    java.io.IOException
        Throws:
        java.sql.SQLException
        java.io.IOException
      • batchExecute

        public BatchCompletion batchExecute()
                                     throws java.sql.SQLException
        Description copied from interface: FbStatement
        Execute the batch on the server.
        Returns:
        batch completion response
        Throws:
        java.sql.SQLException - for database access errors
        java.sql.SQLFeatureNotSupportedException - when this statement implementation does not support batch updates
        See Also:
        FbStatement.supportBatchUpdates()
      • batchCancel

        public void batchCancel()
                         throws java.sql.SQLException
        Description copied from interface: FbStatement
        Cancels the server side batch (that is, clear any rows batched on the server).
        Throws:
        java.sql.SQLException - for database access errors
        java.sql.SQLFeatureNotSupportedException - when this statement implementation does not support batch updates
        See Also:
        FbStatement.supportBatchUpdates()
      • deferredBatchRelease

        public void deferredBatchRelease​(DeferredResponse<java.lang.Void> onResponse)
                                  throws java.sql.SQLException
        Description copied from interface: FbStatement
        Closes (releases) the batch on the server with deferred response processing.

        For implementations that do not supported deferred or async response processing, see FbStatement.deferredBatchCreate(FbBatchConfig, DeferredResponse) for expected behaviour.

        Parameters:
        onResponse - deferred action to call when response is received
        Throws:
        java.sql.SQLException - for database access errors
        java.sql.SQLFeatureNotSupportedException - when this statement implementation does not support batch updates
        See Also:
        FbStatement.supportBatchUpdates()