Sets an application's URLStreamHandlerFactory
.
This method can be called at most once in a given Java Virtual
Machine.
The URLStreamHandlerFactory
instance is used to
construct a stream protocol handler from a protocol name.
If there is a security manager, this method first calls
the security manager's checkSetFactory
method
to ensure the operation is allowed.
This could result in a SecurityException.
fac | the desired factory. |
Error | if the application has already set a factory. | |
SecurityException | if a security manager exists and its
checkSetFactory method doesn't allow
the operation. |
java.net.URL.URL(java.lang.String, java.lang.String,
int, java.lang.String), java.net.URLStreamHandlerFactory, SecurityManager.checkSetFactory
Diagram: URL