Package org.eclipse.jetty.server
Class CachedContentFactory.CachedHttpContent
java.lang.Object
org.eclipse.jetty.server.CachedContentFactory.CachedHttpContent
- All Implemented Interfaces:
HttpContent
- Enclosing class:
CachedContentFactory
MetaData associated with a context Resource.
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.eclipse.jetty.http.HttpContent
HttpContent.ContentFactory
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final String
private final HttpField
private final long
private final HttpField
private final AtomicReference
<ByteBuffer> private final HttpField
private final AtomicReference
<ByteBuffer> private final String
private long
private final HttpField
private final long
private final AtomicReference
<ByteBuffer> private final MimeTypes.Type
private final Resource
-
Constructor Summary
ConstructorsConstructorDescriptionCachedHttpContent
(String pathInContext, Resource resource, Map<CompressedContentFormat, CachedContentFactory.CachedHttpContent> precompressedResources) -
Method Summary
Modifier and TypeMethodDescriptionlong
getETag()
getKey()
Map
<CompressedContentFormat, ? extends HttpContent> protected void
boolean
isCached()
(package private) boolean
isValid()
void
release()
toString()
-
Field Details
-
_key
-
_resource
-
_contentLengthValue
private final long _contentLengthValue -
_contentType
-
_characterEncoding
-
_mimeType
-
_contentLength
-
_lastModified
-
_lastModifiedValue
private final long _lastModifiedValue -
_etag
-
_precompressed
private final Map<CompressedContentFormat,CachedContentFactory.CachedPrecompressedHttpContent> _precompressed -
_indirectBuffer
-
_directBuffer
-
_mappedBuffer
-
_lastAccessed
private volatile long _lastAccessed
-
-
Constructor Details
-
CachedHttpContent
CachedHttpContent(String pathInContext, Resource resource, Map<CompressedContentFormat, CachedContentFactory.CachedHttpContent> precompressedResources)
-
-
Method Details
-
getKey
-
isCached
public boolean isCached() -
getResource
- Specified by:
getResource
in interfaceHttpContent
-
getETag
- Specified by:
getETag
in interfaceHttpContent
-
getETagValue
- Specified by:
getETagValue
in interfaceHttpContent
-
isValid
boolean isValid() -
invalidate
protected void invalidate() -
getLastModified
- Specified by:
getLastModified
in interfaceHttpContent
-
getLastModifiedValue
- Specified by:
getLastModifiedValue
in interfaceHttpContent
-
getContentType
- Specified by:
getContentType
in interfaceHttpContent
-
getContentTypeValue
- Specified by:
getContentTypeValue
in interfaceHttpContent
-
getContentEncoding
- Specified by:
getContentEncoding
in interfaceHttpContent
-
getContentEncodingValue
- Specified by:
getContentEncodingValue
in interfaceHttpContent
-
getCharacterEncoding
- Specified by:
getCharacterEncoding
in interfaceHttpContent
-
getMimeType
- Specified by:
getMimeType
in interfaceHttpContent
-
release
public void release()- Specified by:
release
in interfaceHttpContent
-
getIndirectBuffer
- Specified by:
getIndirectBuffer
in interfaceHttpContent
-
getDirectBuffer
- Specified by:
getDirectBuffer
in interfaceHttpContent
-
getContentLength
- Specified by:
getContentLength
in interfaceHttpContent
-
getContentLengthValue
public long getContentLengthValue()- Specified by:
getContentLengthValue
in interfaceHttpContent
-
getInputStream
- Specified by:
getInputStream
in interfaceHttpContent
- Throws:
IOException
-
getReadableByteChannel
- Specified by:
getReadableByteChannel
in interfaceHttpContent
- Throws:
IOException
-
toString
-
getPrecompressedContents
- Specified by:
getPrecompressedContents
in interfaceHttpContent
-