Package io.deephaven.server.jetty
Class ControlledCacheResource
java.lang.Object
org.eclipse.jetty.util.resource.Resource
io.deephaven.server.jetty.ControlledCacheResource
- All Implemented Interfaces:
Closeable
,AutoCloseable
,org.eclipse.jetty.util.resource.ResourceFactory
public class ControlledCacheResource
extends org.eclipse.jetty.util.resource.Resource
Simple wrapper around the Jetty Resource type, to grant us control over caching features. The current implementation
only removes the last-modified value, but a future version could provide a "real" weak/strong etag.
-
Field Summary
Fields inherited from class org.eclipse.jetty.util.resource.Resource
__defaultUseCaches
-
Method Summary
Modifier and TypeMethodDescriptionorg.eclipse.jetty.util.resource.Resource
void
close()
boolean
delete()
boolean
boolean
exists()
getFile()
getName()
getURI()
int
hashCode()
boolean
isContainedIn
(org.eclipse.jetty.util.resource.Resource r) boolean
long
long
length()
String[]
list()
boolean
renameTo
(org.eclipse.jetty.util.resource.Resource dest) toString()
static ControlledCacheResource
wrap
(org.eclipse.jetty.util.resource.Resource wrapped) Methods inherited from class org.eclipse.jetty.util.resource.Resource
copyTo, fromList, fromList, getAlias, getAllResources, getAssociate, getDefaultUseCaches, getListHTML, getResource, getWeakETag, getWeakETag, isAlias, isContainedIn, isSame, newClassPathResource, newClassPathResource, newResource, newResource, newResource, newResource, newResource, newResource, newSystemResource, resolveAlias, setAssociate, setDefaultUseCaches, toURL
-
Method Details
-
wrap
-
isContainedIn
public boolean isContainedIn(org.eclipse.jetty.util.resource.Resource r) throws MalformedURLException - Specified by:
isContainedIn
in classorg.eclipse.jetty.util.resource.Resource
- Throws:
MalformedURLException
-
close
public void close()- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceCloseable
- Specified by:
close
in classorg.eclipse.jetty.util.resource.Resource
-
exists
public boolean exists()- Specified by:
exists
in classorg.eclipse.jetty.util.resource.Resource
-
isDirectory
public boolean isDirectory()- Specified by:
isDirectory
in classorg.eclipse.jetty.util.resource.Resource
-
lastModified
public long lastModified()- Specified by:
lastModified
in classorg.eclipse.jetty.util.resource.Resource
-
length
public long length()- Specified by:
length
in classorg.eclipse.jetty.util.resource.Resource
-
getURI
- Specified by:
getURI
in classorg.eclipse.jetty.util.resource.Resource
-
getFile
- Specified by:
getFile
in classorg.eclipse.jetty.util.resource.Resource
- Throws:
IOException
-
getName
- Specified by:
getName
in classorg.eclipse.jetty.util.resource.Resource
-
getInputStream
- Specified by:
getInputStream
in classorg.eclipse.jetty.util.resource.Resource
- Throws:
IOException
-
getReadableByteChannel
- Specified by:
getReadableByteChannel
in classorg.eclipse.jetty.util.resource.Resource
- Throws:
IOException
-
delete
- Specified by:
delete
in classorg.eclipse.jetty.util.resource.Resource
- Throws:
SecurityException
-
renameTo
- Specified by:
renameTo
in classorg.eclipse.jetty.util.resource.Resource
- Throws:
SecurityException
-
list
- Specified by:
list
in classorg.eclipse.jetty.util.resource.Resource
-
addPath
public org.eclipse.jetty.util.resource.Resource addPath(String path) throws IOException, MalformedURLException - Specified by:
addPath
in classorg.eclipse.jetty.util.resource.Resource
- Throws:
IOException
MalformedURLException
-
toString
-
hashCode
public int hashCode() -
equals
-