public interface Response extends Message
Response is a Message object that will read itself from a
InputStream upon demand. It is provided by Protocols
as the result of a call to Protocol.createResponse(Command).
A Response is a generalize contract and does not provide the necessary semantics
corresponding to the data for the various response possibilities (such as bulk data
to a collection, value to bytes, etc.)
This specification also does not specify whether a response object can be
reused (to read the same command type response). This is left to the provider
of the implementation. If a provider does NOT wish to re-use responses,
they should raise a ProviderException in any subsequent calls to
Message.read(InputStream). This class, however, does not and will
not provide a 'reset' means.
/**
[TODO: document me!]
| Modifier and Type | Interface and Description |
|---|---|
static class |
Response.Type
A redis server responds with:
Status response - such as
Command.SET
Value Data ("String") - such as Command.GET
Bulk Data - such as Command.KEYS
Multi Bulk Data - such as Command.LRANGE
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
didRead() |
ResponseStatus |
getStatus() |
Response.Type |
getType() |
boolean |
isError() |
boolean isError()
Response.Type getType()
Response.Type of this response.ResponseStatus getStatus()
boolean didRead()
Message.read(java.io.InputStream)Copyright © 2009–2021. All rights reserved.