java.lang.Object | |
↳ | sun.misc.URLClassPath |
This class is used to maintain a search path of URLs for loading classes and resources from both JAR files and directories.
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Creates a new URLClassPath for the given URLs.
| |||||||||||
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Appends the specified URL to the search path of directory and JAR
file URLs from which to load classes and resources.
| |||||||||||
Finds the resource with the specified name on the URL search path
or null if not found or security check fails.
| |||||||||||
Finds all resources on the URL search path with the given name.
| |||||||||||
Finds the first Resource on the URL search path which has the specified
name.
| |||||||||||
Finds all resources on the URL search path with the given name.
| |||||||||||
Returns the original search path of URLs.
| |||||||||||
Convert class path specification into an array of file URLs.
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
![]() |
Creates a new URLClassPath for the given URLs. The URLs will be searched in the order specified for classes and resources. A URL ending with a '/' is assumed to refer to a directory. Otherwise, the URL is assumed to refer to a JAR file.
urls | the directory and JAR file URLs to search for classes and resources |
---|---|
factory | the URLStreamHandlerFactory to use when creating new URLs |
Appends the specified URL to the search path of directory and JAR file URLs from which to load classes and resources.
Finds the resource with the specified name on the URL search path or null if not found or security check fails.
name | the name of the resource |
---|---|
check | whether to perform a security check |
URL
for the resource, or null
if the resource could not be found.
Finds all resources on the URL search path with the given name. Returns an enumeration of the URL objects.
name | the resource name |
---|
Finds the first Resource on the URL search path which has the specified name. Returns null if no Resource could be found.
name | the name of the Resource |
---|---|
check | whether to perform a security check |
Finds all resources on the URL search path with the given name. Returns an enumeration of the Resource objects.
name | the resource name |
---|
Convert class path specification into an array of file URLs. The path of the file is encoded before conversion into URL form so that reserved characters can safely appear in the path.