public class GenericURLStreamHandler extends URLStreamHandler
GenericURLStreamHandler class.
Customized URL stream handler creates dynamically created URL connections from customized URL protocols.Constructor and Description |
---|
GenericURLStreamHandler(Class<? extends URLConnection> urlConnectionClass)
GenericURLStreamHandler
|
GenericURLStreamHandler(Class<? extends URLConnection> urlConnectionClass,
int defaultPort)
GenericURLStreamHandler
|
Modifier and Type | Method and Description |
---|---|
protected int |
getDefaultPort() |
protected URLConnection |
openConnection(URL u) |
equals, getHostAddress, hashCode, hostsEqual, openConnection, parseURL, sameFile, setURL, setURL, toExternalForm
public GenericURLStreamHandler(Class<? extends URLConnection> urlConnectionClass, int defaultPort)
GenericURLStreamHandler
Create URL stream handler with given class and customized default port.public GenericURLStreamHandler(Class<? extends URLConnection> urlConnectionClass)
GenericURLStreamHandler
Create URL stream handler with given class and default port -1.urlConnectionClass
- full qualified classname as String
object.protected int getDefaultPort()
getDefaultPort
in class URLStreamHandler
protected URLConnection openConnection(URL u) throws IOException
openConnection
in class URLStreamHandler
IOException
Copyright © 2020. All rights reserved.