|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjavax.ws.rs.core.Response
com.sun.jersey.core.spi.factory.ResponseImpl
public class ResponseImpl
An implementation of Response.
This implementation supports the declaration of an entity type that will be
utilized when a MessageBodyWriter is selected to write out the
entity.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class javax.ws.rs.core.Response |
|---|
Response.ResponseBuilder, Response.Status, Response.StatusType |
| Constructor Summary | |
|---|---|
protected |
ResponseImpl(int status,
OutBoundHeaders headers,
java.lang.Object entity,
java.lang.reflect.Type entityType)
Construct given a status, entity and metadata. |
protected |
ResponseImpl(Response.StatusType statusType,
OutBoundHeaders headers,
java.lang.Object entity,
java.lang.reflect.Type entityType)
Construct given a status type, entity and metadata. |
| Method Summary | |
|---|---|
java.lang.Object |
getEntity()
Return the response entity. |
java.lang.reflect.Type |
getEntityType()
Get the entity type. |
MultivaluedMap<java.lang.String,java.lang.Object> |
getMetadata()
Get metadata associated with the response as a map. |
int |
getStatus()
Get the status code associated with the response. |
Response.StatusType |
getStatusType()
Get the status type. |
static Response.Status.Family |
toFamilyCode(int statusCode)
|
static Response.StatusType |
toStatusType(int statusCode)
|
| Methods inherited from class javax.ws.rs.core.Response |
|---|
created, fromResponse, noContent, notAcceptable, notModified, notModified, notModified, ok, ok, ok, ok, ok, seeOther, serverError, status, status, status, temporaryRedirect |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
protected ResponseImpl(Response.StatusType statusType,
OutBoundHeaders headers,
java.lang.Object entity,
java.lang.reflect.Type entityType)
statusType - the status typeheaders - the metadata, it is the callers responsibility to copy
the metadata if necessary.entity - the entityentityType - the entity type, it is the callers responsibility to
ensure the entity type is compatible with the entity.
protected ResponseImpl(int status,
OutBoundHeaders headers,
java.lang.Object entity,
java.lang.reflect.Type entityType)
status - the statusheaders - the metadata, it is the callers responsibility to copy
the metadata if necessary.entity - the entityentityType - the entity type, it is the callers responsibility to
ensure the entity type is compatible with the entity.| Method Detail |
|---|
public Response.StatusType getStatusType()
public java.lang.reflect.Type getEntityType()
public int getStatus()
Response
getStatus in class Responsepublic MultivaluedMap<java.lang.String,java.lang.Object> getMetadata()
ResponseRuntimeDelegate.HeaderDelegate
if one is available via
RuntimeDelegate.createHeaderDelegate(java.lang.Class)
for the class of the value or using the values toString method if a
header delegate is not available.
getMetadata in class Responsepublic java.lang.Object getEntity()
ResponseGenericEntity, the value of GenericEntity.getRawType().
getEntity in class ResponseMessageBodyWriterpublic static Response.StatusType toStatusType(int statusCode)
public static Response.Status.Family toFamilyCode(int statusCode)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||