Class StaticURLStreamHandlerFactory
java.lang.Object
cloud.piranha.micro.shrinkwrap.loader.StaticURLStreamHandlerFactory
- All Implemented Interfaces:
URLStreamHandlerFactory
A factory for URL stream handlers using a static map to contain handlers.
This factory should be registered with the JVM early. Later on the HANDLERS
map
can be used to register individual URL stream handlers for various protocols.
- Author:
- Arjan Tijms
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptioncreateURLStreamHandler
(String protocol) static Map<String,
Function<URL, URLConnection>> Returns the handlers.
-
Constructor Details
-
StaticURLStreamHandlerFactory
public StaticURLStreamHandlerFactory()
-
-
Method Details
-
getHandlers
Returns the handlers.- Returns:
- the handlers
-
createURLStreamHandler
- Specified by:
createURLStreamHandler
in interfaceURLStreamHandlerFactory
-