net.i2p.router.tunnel.pool

## Class BuildRequestor

- java.lang.Object
- - net.i2p.router.tunnel.pool.BuildRequestor

-     abstract class BuildRequestor
      extends Object

  Utility class for creating and dispatching tunnel build request messages.

  This class handles:

  - Preparation of tunnel hop IDs
  - Selection of paired or exploratory tunnels for replies
  - Construction of `TunnelBuildMessage`, including legacy and new-style (Short/Variable) formats
  - Garlic encryption for inbound builds
  - Timeout and failure handling

  Paired tunnels are always used (as of 0.9.50+) to improve client isolation and prevent correlation across tunnel pools.

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `(package private) static String` | `PROP_AVAIL_BW`
    `(package private) static String` | `PROP_MAX_BW`
    `(package private) static String` | `PROP_MIN_BW`
    `(package private) static String` | `PROP_REQ_BW`
    `(package private) static int` | `REQUEST_TIMEOUT` Timeout for waiting for a full tunnel build reply.

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `BuildRequestor()`

  - ### Method Summary

    All Methods Static Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `static boolean` | `request(RouterContext ctx, PooledTunnelCreatorConfig cfg, BuildExecutor exec)` Initiates a tunnel build request.

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

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

- - ### Field Detail

    - #### PROP_AVAIL_BW

          static final String PROP_AVAIL_BW

      See Also:
        Constant Field Values

    - #### PROP_MAX_BW

          static final String PROP_MAX_BW

      See Also:
        Constant Field Values

    - #### PROP_MIN_BW

          static final String PROP_MIN_BW

      See Also:
        Constant Field Values

    - #### PROP_REQ_BW

          static final String PROP_REQ_BW

      See Also:
        Constant Field Values

    - #### REQUEST_TIMEOUT

          static final int REQUEST_TIMEOUT

      Timeout for waiting for a full tunnel build reply.

  - ### Constructor Detail

    - #### BuildRequestor

          BuildRequestor()

  - ### Method Detail

    - #### request

          public static boolean request(RouterContext ctx,
                                        PooledTunnelCreatorConfig cfg,
                                        BuildExecutor exec)

      Initiates a tunnel build request.
      Parameters:
        `ctx` - router context
        `cfg` - tunnel configuration (must have ReplyMessageId set)
        `exec` - executor to notify on completion
      Returns:
        `true` if request was successfully dispatched