org.apache.hc.client5.http.impl.nio

## Class MultuhomeConnectionInitiator

- java.lang.Object
- - org.apache.hc.client5.http.impl.nio.MultuhomeConnectionInitiator

All Implemented Interfaces:
  ConnectionInitiator

    @Contract(threading=SAFE_CONDITIONAL)
    public final class MultuhomeConnectionInitiator
    extends Object
    implements ConnectionInitiator

Multi-home DNS aware implementation of `ConnectionInitiator`.

Since:
  5.0

### Constructor Summary

Constructors
Constructor and Description
`MultuhomeConnectionInitiator(ConnectionInitiator connectionInitiator, DnsResolver dnsResolver)`

### Method Summary

Methods
`Future<IOSession>` `connect(NamedEndpoint remoteEndpoint, SocketAddress remoteAddress, SocketAddress localAddress, Timeout connectTimeout, Object attachment, FutureCallback<IOSession> callback)`
`Future<IOSession>` `connect(NamedEndpoint remoteEndpoint, SocketAddress localAddress, Timeout connectTimeout, Object attachment, FutureCallback<IOSession> callback)`

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

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

### Constructor Detail

#### MultuhomeConnectionInitiator

    public MultuhomeConnectionInitiator(ConnectionInitiator connectionInitiator,
                                DnsResolver dnsResolver)

### Method Detail

#### connect

    public Future<IOSession> connect(NamedEndpoint remoteEndpoint,
                            SocketAddress remoteAddress,
                            SocketAddress localAddress,
                            Timeout connectTimeout,
                            Object attachment,
                            FutureCallback<IOSession> callback)

Specified by:
  `connect` in interface `ConnectionInitiator`

#### connect

    public Future<IOSession> connect(NamedEndpoint remoteEndpoint,
                            SocketAddress localAddress,
                            Timeout connectTimeout,
                            Object attachment,
                            FutureCallback<IOSession> callback)