public final class ClasspathResource extends AbstractResource
Resource for files on the classpath (as defined by a ClassLoader).| Constructor and Description |
|---|
ClasspathResource(java.lang.ClassLoader classLoader,
java.lang.String path) |
ClasspathResource(java.lang.String path) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(java.lang.Object obj) |
int |
hashCode() |
protected Resource |
newResource(java.lang.String path)
Factory method provided by subclasses.
|
java.lang.String |
toString() |
java.net.URL |
toURL()
Returns the URL for the resource, or null if it does not exist.
|
exists, forFile, forLocale, getFile, getFolder, getPath, isVirtual, openStream, validateURL, withExtensionacquireReadLock, downgradeWriteLockToReadLock, releaseReadLock, releaseWriteLock, takeWriteLock, upgradeReadLockToWriteLockpublic ClasspathResource(java.lang.String path)
public ClasspathResource(java.lang.ClassLoader classLoader, java.lang.String path)
protected Resource newResource(java.lang.String path)
AbstractResourcenewResource in class AbstractResourcepublic java.net.URL toURL()
Resourcepublic boolean equals(java.lang.Object obj)
equals in class java.lang.Objectpublic int hashCode()
hashCode in class java.lang.Objectpublic java.lang.String toString()
toString in class java.lang.Object${project.version} - Copyright © 2003-2015 The Apache Software Foundation.