|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.cocoon.caching.CachedResponse
public class CachedResponse
This is a cached response. This can either contain a byte array with
the complete character response or a byte array with compiled SAX events.
This class replaces the CachedEventObject and the
CachedStreamObject.
| Field Summary | |
|---|---|
protected String |
contentType
|
protected Long |
expires
|
protected long |
lastModified
|
protected byte[] |
response
|
protected SourceValidity[] |
validityObjects
|
| Constructor Summary | |
|---|---|
CachedResponse(SourceValidity[] validityObjects,
byte[] response)
Create a new entry for the cache. |
|
CachedResponse(SourceValidity[] validityObjects,
byte[] response,
Long expires)
Create a new entry for the cache. |
|
CachedResponse(SourceValidity validityObject,
byte[] response)
Create a new entry for the cache. |
|
| Method Summary | |
|---|---|
String |
getContentType()
|
Long |
getExpires()
Get the configured expires. |
long |
getLastModified()
|
byte[] |
getResponse()
Get the cached response. |
SourceValidity[] |
getValidityObjects()
Get the validity objects |
void |
setContentType(String value)
|
void |
setExpires(Long newExpires)
Set the (newly) configured expires. |
protected long |
setLastModified(long lastModified)
Set the (newly) configured last modified. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected final SourceValidity[] validityObjects
protected final byte[] response
protected Long expires
protected final long lastModified
protected String contentType
| Constructor Detail |
|---|
public CachedResponse(SourceValidity[] validityObjects,
byte[] response)
validityObjects - The SourceValidity objects in the order
they occured in the pipelineresponse - The cached sax stream or character stream
public CachedResponse(SourceValidity validityObject,
byte[] response)
validityObject - The SourceValidity objectresponse - The cached sax stream or character stream
public CachedResponse(SourceValidity[] validityObjects,
byte[] response,
Long expires)
validityObjects - The SourceValidity objects in the order
they occured in the pipelineresponse - The cached sax stream or character streamexpires - The configured expires, or null if no
expires was defined.| Method Detail |
|---|
public SourceValidity[] getValidityObjects()
public byte[] getResponse()
public Long getExpires()
public void setExpires(Long newExpires)
protected long setLastModified(long lastModified)
public long getLastModified()
public String getContentType()
public void setContentType(String value)
value - The content type to cache.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||