URLClassLoader: Circumstance under which new URLs will be created is not clear.
From the spec (6-b96):
----------------------------------------------------------------
public URLClassLoader(URL[] urls,
ClassLoader parent,
URLStreamHandlerFactory factory)
...
The factory argument will be used as the stream handler factory to obtain protocol handlers when creating new jar URLs.
...
----------------------------------------------------------------
There are no words about when and why new URLs must be created. So implementor can avoid creation of new URLs at all. So factory parameter is useless from developer point of view, because developer haven't got any information if factory will be used or not.
Thus without having documented in the spec when and/or why new URLs is going to be created it is not possible to create any particular URLStreamHandlerFactory (USHF) implementation to be passed to 3-argument UCL's constructor as a parameter value.
From the spec (6-b96):
----------------------------------------------------------------
public URLClassLoader(URL[] urls,
ClassLoader parent,
URLStreamHandlerFactory factory)
...
The factory argument will be used as the stream handler factory to obtain protocol handlers when creating new jar URLs.
...
----------------------------------------------------------------
There are no words about when and why new URLs must be created. So implementor can avoid creation of new URLs at all. So factory parameter is useless from developer point of view, because developer haven't got any information if factory will be used or not.
Thus without having documented in the spec when and/or why new URLs is going to be created it is not possible to create any particular URLStreamHandlerFactory (USHF) implementation to be passed to 3-argument UCL's constructor as a parameter value.
- relates to
-
JDK-6442185 URLClassLoader(urls, parent, factory) Mean of "factory" parameter is not clear
- Closed