An in memory Resource created from a URL
| Modifier and Type | Field and Description |
|---|---|
| private final byte[] | |
| private final Instant | |
| private final URI |
| Access | Constructor and Description |
|---|---|
| pack-priv |
| Modifier and Type | Method and Description |
|---|---|
| public boolean | exists()
Overrides org. Files#exists(Path, LinkOption. with the following parameters:
getPath() and LinkOption#NOFOLLOW_LINKS.
|
| public Collection | getAllResources()
Overrides org. |
| public String | getFileName()
Implements abstract org. The file name of the resource. |
| public String | getName()
Implements abstract org. |
| public Path | getPath()
Implements abstract org. |
| public URI | getURI()
Implements abstract org. |
| public boolean | isContainedIn(Resource
the containing resource container)Overrides org. |
| public boolean | isDirectory()
Implements abstract org. |
| public boolean | isReadable()
Implements abstract org. |
| public Instant | lastModified()
Overrides org. |
| public long | |
| public List | list()
Overrides org. List of contents of a directory |
| public InputStream | newInputStream()
Overrides org. |
| public ReadableByteChannel | newReadableByteChannel()
Overrides org. |
| public Resource | resolve(String
the encoded subUriPath subUriPath)Implements abstract org. |
| public String |
| _bytes | back to summary |
|---|---|
| private final byte[] _bytes | |
| _created | back to summary |
|---|---|
| private final Instant _created | |
| _uri | back to summary |
|---|---|
| private final URI _uri | |
| MemoryResource | back to summary |
|---|---|
| pack-priv MemoryResource(URL url) | |
| exists | back to summary |
|---|---|
| public boolean exists() Overrides org. Doc from org. Equivalent to
| |
| getAllResources | back to summary |
|---|---|
| public Collection Overrides org. Doc from org. Get a deep collection of contained resources.
| |
| getFileName | back to summary |
|---|---|
| public String getFileName() Implements abstract org. Doc from org. The file name of the resource. This is the last segment of the path. | |
| getName | back to summary |
|---|---|
| public String getName() Implements abstract org. Doc from org. The full name of the resource. | |
| getPath | back to summary |
|---|---|
| public Path getPath() Implements abstract org. Doc from org. Return the Path corresponding to this resource. | |
| getURI | back to summary |
|---|---|
| public URI getURI() Implements abstract org. Doc from org. URI representing the resource. | |
| isContainedIn | back to summary |
|---|---|
| public boolean isContainedIn(Resource container) Overrides org. Doc from org. Return true if this resource is contained in the Resource r, either because r is a folder or a jar file or any form of resource capable of containing other resources. | |
| isDirectory | back to summary |
|---|---|
| public boolean isDirectory() Implements abstract org. Doc from org. Return true if resource represents a directory of potential resources.
| |
| isReadable | back to summary |
|---|---|
| public boolean isReadable() Implements abstract org. Doc from org. True if the resource is readable.
| |
| lastModified | back to summary |
|---|---|
| public Instant lastModified() Overrides org. Doc from org. The time the resource was last modified.
| |
| length | back to summary |
|---|---|
| public long length() Overrides org. Doc from org. Length of the resource.
| |
| list | back to summary |
|---|---|
| public List Overrides org. Doc from org. List of contents of a directory Ordering is | |
| newInputStream | back to summary |
|---|---|
| public InputStream newInputStream() throws IOException Overrides org. Doc from org. Creates a new input stream to the resource.
| |
| newReadableByteChannel | back to summary |
|---|---|
| public ReadableByteChannel newReadableByteChannel() throws IOException Overrides org. Doc from org. Readable ByteChannel for the resource.
| |
| resolve | back to summary |
|---|---|
| public Resource resolve(String subUriPath) Implements abstract org. Doc from org. Resolve an existing Resource. | |
| toString | back to summary |
|---|---|
| public String toString() Overrides java. Doc from java. Returns a string representation of the object. | |