java.net.URLStreamHandlerFactory
public class CustomURLStreamHandlerFactory
extends java.lang.Object
implements java.net.URLStreamHandlerFactory
URLStreamHandlerFactory
.
The handlers it can dispense are configured using a map; the keys of
the map are protocol names and its values are the names of classes
which implement URLStreamHandler
(and have no-arg
constructors).URL
Constructor | Description |
---|---|
CustomURLStreamHandlerFactory() |
Constructs a no-op handler factory.
|
CustomURLStreamHandlerFactory(java.util.Map classMap) |
Constructs a handler factory initialised with a given
protocol->classname map.
|
Modifier and Type | Method | Description |
---|---|---|
java.net.URLStreamHandler |
createURLStreamHandler(java.lang.String protocol) |
|
java.util.Map |
getHandlerClassMap() |
Returns the protocol->>classname map that describes this factory.
|
public CustomURLStreamHandlerFactory()
public CustomURLStreamHandlerFactory(java.util.Map classMap)
classMap
- handler class mappublic java.util.Map getHandlerClassMap()
public java.net.URLStreamHandler createURLStreamHandler(java.lang.String protocol)
createURLStreamHandler
in interface java.net.URLStreamHandlerFactory
Copyright © 2018 Central Laboratory of the Research Councils. All Rights Reserved.