public class URLFactory extends Object
URL
's. This factory creates URL
's that in additional to the standard URL
's
capability of loading resources using http, https, file, etc. also makes it possible to load resources from
the applications classpath. To load a resource from classpath, the url must be prefixed either with classpath:
or resource:
To ensure that we support classpath resources, this class should be used instead of new URL(pURL)
Constructor and Description |
---|
URLFactory() |
Modifier and Type | Method and Description |
---|---|
static URL |
toURL(String pURL)
Creates an
URL based on the provided string |
public static URL toURL(String pURL) throws MalformedURLException
URL
based on the provided stringpURL
- the urlURL
MalformedURLException
- if the url is not a proper URLCopyright © 2019. All rights reserved.