java.lang.Cloneable, java.lang.Comparable<Resource>, java.lang.Iterable<Resource>, ResourceCollection, URLProviderpublic class JavaResource extends AbstractClasspathResource implements URLProvider
AbstractClasspathResource.ClassLoaderWithFlagdescription, location, projectMAGIC, UNKNOWN_DATETIME, UNKNOWN_SIZE| Constructor | Description |
|---|---|
JavaResource() |
Default constructor.
|
JavaResource(java.lang.String name,
Path path) |
Construct a new JavaResource using the specified name and
classpath.
|
| Modifier and Type | Method | Description |
|---|---|---|
int |
compareTo(Resource another) |
Compare this JavaResource to another Resource.
|
protected JavaResource |
getCheckedRef() |
Performs the check for circular references and returns the
referenced object.
|
java.net.URL |
getURL() |
Get the URL represented by this Resource.
|
protected java.io.InputStream |
openInputStream(java.lang.ClassLoader cl) |
open the input stream from a specific classloader
|
createClasspath, dieOnCircularReference, getClassLoader, getClasspath, getInputStream, getLoader, isExists, setClasspath, setClasspathRef, setLoaderRef, setParentFirst, setRefidcheckAttributesAllowed, checkChildrenAllowed, circularReference, dieOnCircularReference, dieOnCircularReference, getCheckedRef, getCheckedRef, getCheckedRef, getDataTypeName, getRefid, invokeCircularReferenceCheck, isChecked, isReference, noChildrenAllowed, pushAndInvokeCircularReferenceCheck, setChecked, tooManyAttributesfinalize, getClass, notify, notifyAll, wait, wait, waitgetDescription, getLocation, getProject, log, log, setDescription, setLocation, setProjectas, asOptional, clone, equals, getLastModified, getMagicNumber, getName, getOutputStream, getSize, hashCode, isDirectory, isFilesystemOnly, iterator, setDirectory, setExists, setLastModified, setName, setSize, size, toLongString, toStringisEmpty, streampublic JavaResource()
public JavaResource(java.lang.String name,
Path path)
name - the resource name.path - the classpath.protected java.io.InputStream openInputStream(java.lang.ClassLoader cl)
throws java.io.IOException
openInputStream in class AbstractClasspathResourcecl - the classloader to use. Will be null if the system
classloader is usedjava.io.IOException - if an error occurs.public java.net.URL getURL()
getURL in interface URLProviderpublic int compareTo(Resource another)
compareTo in interface java.lang.Comparable<Resource>compareTo in class Resourceanother - the other Resource against which to compare.protected JavaResource getCheckedRef()
DataTypegetCheckedRef in class Resource