Module org.firebirdsql.jaybird
Package org.firebirdsql.gds.ng.wire.version16

# Class V16WireOperations

java.lang.Object
org.firebirdsql.gds.ng.wire.AbstractWireOperations
org.firebirdsql.gds.ng.wire.version10.V10WireOperations
org.firebirdsql.gds.ng.wire.version11.V11WireOperations
org.firebirdsql.gds.ng.wire.version13.V13WireOperations
org.firebirdsql.gds.ng.wire.version15.V15WireOperations
org.firebirdsql.gds.ng.wire.version16.V16WireOperations

All Implemented Interfaces:
  `FbWireOperations`

Direct Known Subclasses:
  `V18WireOperations`

public class V16WireOperations extends V15WireOperations

Since:
  5
Author:
  Mark Rotteveel

- ## Nested Class Summary

  ## Nested classes/interfaces inherited from interface org.firebirdsql.gds.ng.wire.FbWireOperations

  `FbWireOperations.ProcessAttachCallback`

- ## Field Summary

  Fields
  Modifier and Type
  Field
  Description
  `protected static final int`
  `BATCH_LIMIT`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `V16WireOperations(WireConnection<?,?> connection, WarningMessageCallback defaultWarningMessageCallback)`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `protected void`
  `afterEnqueueDeferredAction()`
  Action to perform after the deferred action has been queued in `V11WireOperations.enqueueDeferredAction(DeferredAction)`.
  `protected void`
  `afterProcessDeferredActions(int processedDeferredActions)`
  Can be used for additional actions after processing deferred actions (e.g.
  `void`
  `completeDeferredActions()`
  Completes pending deferred actions.
  `protected int`
  `getBatchSyncOperation()`
  `protected BatchCompletionResponse`
  `readBatchCompletionResponse(XdrInputStream xdrIn)`
  Reads the batch completion response (`op_batch_cs`) without reading the operation code itself.

  ### Methods inherited from class org.firebirdsql.gds.ng.wire.version15.V15WireOperations

  `readCryptKeyCallback, writeCryptKeyCallback`

  ### Methods inherited from class org.firebirdsql.gds.ng.wire.version13.V13WireOperations

  `authReceiveResponse, enableEncryption, handleCryptKeyCallback`

  ### Methods inherited from class org.firebirdsql.gds.ng.wire.version11.V11WireOperations

  `completeDeferredActionsRequiresSync, deferredActionCount, enqueueDeferredAction, processDeferredActions`

  ### Methods inherited from class org.firebirdsql.gds.ng.wire.AbstractWireOperations

  `addServerKeys, clearServerKeys, consumePackets, getAttachProperties, getClientAuthBlock, getConnection, getDefaultWarningMessageCallback, getEncoding, getPluginSpecificData, getXdrIn, getXdrOut, getXdrStreamAccess, processOperation, processResponse, processResponseWarnings, readGenericResponse, readInlineBlobResponse, readNextOperation, readOperationResponse, readResponse, readSqlResponse, readStatusVector, readStatusVector, setNetworkTimeout, withLock, writeDirect`

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Field Details

  - ### BATCH_LIMIT

    protected static final int BATCH_LIMIT
    See Also:
      - Constant Field Values

- ## Constructor Details

  - ### V16WireOperations

    public V16WireOperations(WireConnection<?,?> connection, WarningMessageCallback defaultWarningMessageCallback)

- ## Method Details

  - ### afterEnqueueDeferredAction

    protected void afterEnqueueDeferredAction() throws SQLException
    Description copied from class: `V11WireOperations`
    Action to perform after the deferred action has been queued in `V11WireOperations.enqueueDeferredAction(DeferredAction)`.

    This method should only be called by `V11WireOperations.enqueueDeferredAction(DeferredAction)`, and can be used to implement forcing processing of deferred actions if too many are queued.

    Overrides:
      `afterEnqueueDeferredAction` in class `V11WireOperations`
    Throws:
      `SQLException` - for errors forcing handling of oversized queue using `op_ping` (or `op_batch_sync`)

  - ### completeDeferredActions

    public void completeDeferredActions() throws SQLException
    Description copied from interface: `FbWireOperations`
    Completes pending deferred actions.

    Wire protocol implementations that do not support deferred actions should simply do nothing.

    Specified by:
      `completeDeferredActions` in interface `FbWireOperations`
    Overrides:
      `completeDeferredActions` in class `V11WireOperations`
    Throws:
      `SQLException` - for errors forcing ping/batch sync

  - ### getBatchSyncOperation

    protected int getBatchSyncOperation()
    Returns:
      operation code that synchronizes deferred batch operations (`op_ping` or `op_batch_sync`)

  - ### afterProcessDeferredActions

    protected void afterProcessDeferredActions(int processedDeferredActions)
    Description copied from class: `V11WireOperations`
    Can be used for additional actions after processing deferred actions (e.g. trim a large deferred actions list to its default capacity).

    This implementation trims if `processedDeferredActions > 10`. When overridden, it is recommend to call this method through `super` to still trim (e.g. in a more limited set of circumstances) and perform any other actions this method may perform. If the overridden method wants to forgo trimming, it should pass `-1` for `processedDeferredActions`.

    Overrides:
      `afterProcessDeferredActions` in class `V11WireOperations`
    Parameters:
      `processedDeferredActions` - number of processed deferred actions, or `-1` to ensure no trim is performed

  - ### readBatchCompletionResponse

    protected BatchCompletionResponse readBatchCompletionResponse(XdrInputStream xdrIn) throws SQLException, IOException
    Description copied from class: `AbstractWireOperations`
    Reads the batch completion response (`op_batch_cs`) without reading the operation code itself.
    Overrides:
      `readBatchCompletionResponse` in class `AbstractWireOperations`
    Parameters:
      `xdrIn` - XDR input stream to read
    Returns:
      batch completion response
    Throws:
      `SQLException` - for errors reading the response from the connection
      `SQLFeatureNotSupportedException` - when the protocol version does not support this response
      `IOException` - for errors reading the response from the connection