Package org.infinispan.rest
Class InfinispanCacheResponse
- java.lang.Object
-
- org.infinispan.rest.InfinispanResponse
-
- org.infinispan.rest.InfinispanCacheResponse
-
public class InfinispanCacheResponse extends InfinispanResponse
- Since:
- 9.2
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidaddSpecificHeaders(io.netty.handler.codec.http.FullHttpResponse response)voidcacheControl(CacheControl cacheControl)Adds Cache Control headers.voidclusterNodeName(String nodeName)AddsCluster-Node-Nameheader.voidclusterPrimaryOwner(String primaryOwner)AddsCluster-Primary-Ownerheader.voidclusterServerAddress(String serverAddress)AddsCluster-Server-Addressheader.voidetag(String etag)Adds ETAG.voidexpires(Date expires)Addsexpiresheader.static InfinispanCacheResponseinReplyTo(InfinispanRequest request)Creates anInfinispanResponseas a reply to specificInfinispanRequest.voidlastModified(Date lastModified)Addlast-modifiedheader.voidmaxIdle(long maxIdle)AddsmaxIdleTimeSecondsheader.voidtimeToLive(long lifespan)-
Methods inherited from class org.infinispan.rest.InfinispanResponse
authenticate, authenticateHeader, charset, contentAsBytes, contentAsText, contentType, httpVersion, isKeepAlive, status, toNettyHttpResponse
-
-
-
-
Method Detail
-
addSpecificHeaders
protected void addSpecificHeaders(io.netty.handler.codec.http.FullHttpResponse response)
- Overrides:
addSpecificHeadersin classInfinispanResponse
-
inReplyTo
public static InfinispanCacheResponse inReplyTo(InfinispanRequest request)
Creates anInfinispanResponseas a reply to specificInfinispanRequest.- Parameters:
request- Request to reply to.- Returns:
- Response object.
-
etag
public void etag(String etag)
Adds ETAG.- Parameters:
etag- ETag value to be added.
-
cacheControl
public void cacheControl(CacheControl cacheControl)
Adds Cache Control headers.- Parameters:
cacheControl- Cache Control headers.
-
lastModified
public void lastModified(Date lastModified)
Addlast-modifiedheader.- Parameters:
lastModified-last-modifiedheader value.
-
expires
public void expires(Date expires)
Addsexpiresheader.- Parameters:
expires-expiresheader value.
-
timeToLive
public void timeToLive(long lifespan)
-
maxIdle
public void maxIdle(long maxIdle)
AddsmaxIdleTimeSecondsheader.- Parameters:
maxIdle-maxIdleTimeSecondsheader value.
-
clusterPrimaryOwner
public void clusterPrimaryOwner(String primaryOwner)
AddsCluster-Primary-Ownerheader.- Parameters:
primaryOwner-Cluster-Primary-Ownerheader value.
-
clusterNodeName
public void clusterNodeName(String nodeName)
AddsCluster-Node-Nameheader.- Parameters:
nodeName-Cluster-Node-Nameheader value.
-
clusterServerAddress
public void clusterServerAddress(String serverAddress)
AddsCluster-Server-Addressheader.- Parameters:
serverAddress-Cluster-Server-Addressheader value.
-
-