ice.net.pac
Interface PacCallback


public interface PacCallback

Defines the callback interface for the PAC specification. The PacCallback registered at the PacManager implements the actual communication with the end-user.

Usage:
Following is a code snippet of how the PacCallback can be implemented and used:
    try {
        PacManager _pacManager =
            new PacManager(new URL("http://localhost/pac/proxy.pac"));
        _pacManager.setPacCallback(
            new PacCallback() {
                public boolean
                ignoreProxies() {
                    return
                        showConfirmationDialog(
                            "Do you want to ignore proxies and go direct?");
                }

                public boolean
                retryProxies() {
                    return
                        showConfirmationDialog(
                            "Do you want to retry using proxies?");
                }
            });
    } catch (MalformedURLException exception) {
        // handle the exception.
    }

Since:
1.5
Version:
1.5
Author:
Jack van Ooststroom
See Also:
PacManager.getPacCallback(), PacManager.setPacCallback(PacCallback)

Method Summary
 boolean ignoreProxies()
          Ask the end-user for confirmation if proxies should be disabled, so that direct connections can be made in the future.
 boolean retryProxies()
          Ask the end-user for confirmation if proxies should be retried, so that no direct connections can be made in the future.
 

Method Detail

ignoreProxies

public boolean ignoreProxies()

Ask the end-user for confirmation if proxies should be disabled, so that direct connections can be made in the future.

Returns:
true if proxies should be ignored, false if not.
See Also:
PacManager.areProxiesEnabled()

retryProxies

public boolean retryProxies()

Ask the end-user for confirmation if proxies should be retried, so that no direct connections can be made in the future.

Returns:
true if proxies should be retried, false if not.
See Also:
PacManager.areProxiesEnabled()