Interface TransportRequest


public interface TransportRequest
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    Cancels request associated with the object.
    Returns reference to request configuration.
    <T> T
    Gives access to transport delegate.
    boolean
    Returns indication if request was canceled on client side
  • Method Details

    • getDelegate

      <T> T getDelegate()
      Gives access to transport delegate. Used strictly only by transport.
      Type Parameters:
      T - - Type of delegate
      Returns:
      internal transport request object
    • getConfig

      Map<String,Object> getConfig()
      Returns reference to request configuration. Implementation should store only copy because configuration map is created for each request separately
      Returns:
      request configuration map
    • cancel

      boolean cancel()
      Cancels request associated with the object. Implementation should treat this method like close() and release all resource. When request is canceled it cannot be reused. All reusable objects should be saved elsewhere. In many cases cancellation of IO operation is problematic and result of this method should not be used in core logic. Operation is idempotent and can be called on canceled request multiple times.
      Returns:
      result of operation. True if request was canceled for sure. False when result cannot be known.
    • isCancelled

      boolean isCancelled()
      Returns indication if request was canceled on client side
      Returns:
      true if request was canceled