Class AbstractRequestContext<T>

java.lang.Object
org.opendaylight.openflowplugin.impl.rpc.AbstractRequestContext<T>
All Implemented Interfaces:
AutoCloseable, RequestContext<T>, RequestFutureContext<T>

public abstract class AbstractRequestContext<T> extends Object implements RequestContext<T>
  • Constructor Summary

    Constructors
    Modifier
    Constructor
    Description
    protected
    Deprecated.
    protected
    AbstractRequestContext(org.opendaylight.yangtools.yang.common.Uint32 xid)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    final com.google.common.util.concurrent.ListenableFuture<org.opendaylight.yangtools.yang.common.RpcResult<T>>
    Method returns future to be used for handling device requests.
    final long
    Returns request timeout value.
    final Xid
    Returns XID generated for this request.
    final void
    setResult(org.opendaylight.yangtools.yang.common.RpcResult<T> result)
     
    final void
    setWaitTimeout(long waitTimeout)
    Sets request timeout value.

    Methods inherited from class java.lang.Object

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

    Methods inherited from interface org.opendaylight.openflowplugin.api.openflow.device.RequestContext

    close
  • Constructor Details

    • AbstractRequestContext

      protected AbstractRequestContext(org.opendaylight.yangtools.yang.common.Uint32 xid)
    • AbstractRequestContext

      @Deprecated protected AbstractRequestContext(Long xid)
      Deprecated.
  • Method Details

    • getFuture

      public final com.google.common.util.concurrent.ListenableFuture<org.opendaylight.yangtools.yang.common.RpcResult<T>> getFuture()
      Description copied from interface: RequestFutureContext
      Method returns future to be used for handling device requests.
      Specified by:
      getFuture in interface RequestFutureContext<T>
      Returns:
      rpc result
    • setResult

      public final void setResult(org.opendaylight.yangtools.yang.common.RpcResult<T> result)
      Specified by:
      setResult in interface RequestFutureContext<T>
    • getXid

      public final Xid getXid()
      Description copied from interface: RequestContext
      Returns XID generated for this request.
      Specified by:
      getXid in interface RequestContext<T>
      Returns:
      Allocated XID, or null if the device has disconnected.
    • getWaitTimeout

      public final long getWaitTimeout()
      Description copied from interface: RequestContext
      Returns request timeout value.
      Specified by:
      getWaitTimeout in interface RequestContext<T>
      Returns:
      timeout
    • setWaitTimeout

      public final void setWaitTimeout(long waitTimeout)
      Description copied from interface: RequestContext
      Sets request timeout value.
      Specified by:
      setWaitTimeout in interface RequestContext<T>