"Fossies" - the Fresh Open Source Software archive

Member "rabbit4.11/htdocs/javadoc/rabbit/io/Resolver.html" of archive rabbit4.11-bin.tar.gz:


Caution: In this restricted "Fossies" environment the current HTML page may not be correctly presentated and may have some non-functional links. Alternatively you can here view or download the uninterpreted source code. That can be also achieved for any archive member file by clicking within an archive contents listing on the first character of the file(path) respectively on the according byte size field.



rabbit.io
Interface Resolver

All Known Implementing Classes:
ProxyResolver, SimpleResolver

public interface Resolver

An interface to handle name lookups.

Author:
Robert Olofsson

Method Summary
 int getConnectPort(int port)
          Get the port to use for connecting to a given port.
 void getInetAddress(URL url, InetAddressListener listener)
          Get the InetAddress for a given url.
 String getProxyAuthString()
          Get the currently set proxy authentication.
 boolean isProxyConnected()
          Check if the resolver is using a proxy or not.
 

Method Detail

getInetAddress

void getInetAddress(URL url,
                    InetAddressListener listener)
Get the InetAddress for a given url. Normally the InetAddress of the url host, but might be the InetAddress of the chained proxy to use.

Parameters:
url - the URL to lookup.
listener - the InetAddressListener to notify when lookup is done.

getConnectPort

int getConnectPort(int port)
Get the port to use for connecting to a given port. Normally port is returned, but if there is a chained proxy, then the proxy port is returned instead.

Parameters:
port - the port number we are trying to use
Returns:
the tcp port number to use

isProxyConnected

boolean isProxyConnected()
Check if the resolver is using a proxy or not.

Returns:
true if there is an upstream proxy

getProxyAuthString

String getProxyAuthString()
Get the currently set proxy authentication.

Returns:
the upstream proxy basic identification header