Package io.microsphere.net
Class ServiceLoaderURLStreamHandlerFactory
- java.lang.Object
-
- io.microsphere.net.DelegatingURLStreamHandlerFactory
-
- io.microsphere.net.ServiceLoaderURLStreamHandlerFactory
-
- All Implemented Interfaces:
java.net.URLStreamHandlerFactory
public class ServiceLoaderURLStreamHandlerFactory extends DelegatingURLStreamHandlerFactory
DecoratingURLStreamHandlerFactory
class delegates the composite ofURLStreamHandlerFactory
andURLStreamHandler
instances that are loaded by the JDK'sServiceLoader
.First, the
DelegatingURLStreamHandlerFactory.createURLStreamHandler(String)
method tries to create an instance ofURLStreamHandler
vid eachURLStreamHandlerFactory
delegate in theprioritized
order, once some one returns a non-null result, it will be taken. Otherwise,ExtendableProtocolURLStreamHandler
delegates will be used to resolve the result if possible.- Since:
- 1.0.0
- Author:
- Mercy
- See Also:
Prioritized
-
-
Constructor Summary
Constructors Constructor Description ServiceLoaderURLStreamHandlerFactory()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static void
attach()
-
Methods inherited from class io.microsphere.net.DelegatingURLStreamHandlerFactory
createURLStreamHandler, getDelegate
-
-