Package com.jogamp.common.net
Class GenericURLStreamHandlerFactory
- java.lang.Object
-
- com.jogamp.common.net.GenericURLStreamHandlerFactory
-
- All Implemented Interfaces:
URLStreamHandlerFactory
public class GenericURLStreamHandlerFactory extends Object implements URLStreamHandlerFactory
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description URLStreamHandlercreateURLStreamHandler(String protocol)URLStreamHandlergetHandler(String protocol)Returns theprotocolhandler previously set viasetHandler(String, URLStreamHandler), or null if none was set.static GenericURLStreamHandlerFactoryregister()Returns the singleton instance of the registered GenericURLStreamHandlerFactory or null if registration was not successful.URLStreamHandlersetHandler(String protocol, URLStreamHandler handler)Sets thehandlerforprotocol.
-
-
-
Method Detail
-
setHandler
public final URLStreamHandler setHandler(String protocol, URLStreamHandler handler)
Sets thehandlerforprotocol.- Returns:
- the previous set
handler, or null if none was set.
-
getHandler
public final URLStreamHandler getHandler(String protocol)
Returns theprotocolhandler previously set viasetHandler(String, URLStreamHandler), or null if none was set.
-
createURLStreamHandler
public final URLStreamHandler createURLStreamHandler(String protocol)
- Specified by:
createURLStreamHandlerin interfaceURLStreamHandlerFactory
-
register
public static GenericURLStreamHandlerFactory register()
Returns the singleton instance of the registered GenericURLStreamHandlerFactory or null if registration was not successful.Registration is only performed once.
-
-