java.net.Authenticator class

I have some questions about tje java.net.Authenticator class. I am using Code Sample 6 from:

http://java.sun.com/features/2002/11/hilevel_network.html

1. What is the lifespan of an Authenticator? If an application opens a new url each time a button is clicked:

URL url =new URL(someURLString);

Object content = url.getContent();

.....

Should the authenticator prompt for credentials once or each time a new connection is opened?

2. Normally, if you connect to a resource in a windows network requiring authentication, the o/s may display a prompt like:

http://java.sun.com/features/2002/11/images/fig3.gif

Code Sample 6 uses JOptionPane.showConfirmDialog to create a custom prompt like:

http://java.sun.com/features/2002/11/images/fig7.gif

Does the custom JOptionPane prompt take the place of the o/s prompt? In other words, the only prompt displayed will be the JOptionPane prompt?

3. Does the Authenticator class work with IIS?

[1046 byte] By [jDaze_a] at [2007-10-3 6:02:15]
# 1
Has anyone used this class?Message was edited by: jDaze_
jDaze_a at 2007-7-15 0:44:25 > top of Java-index,Java Essentials,New To Java...