public class BuiltResponse
extends javax.ws.rs.core.Response
| Modifier and Type | Field and Description |
|---|---|
protected java.lang.annotation.Annotation[] |
annotations |
protected java.lang.Object |
entity |
protected java.lang.Class |
entityClass |
protected java.lang.reflect.Type |
genericType |
protected boolean |
isClosed |
protected Headers<java.lang.Object> |
metadata |
protected HeaderValueProcessor |
processor |
protected int |
status |
| Constructor and Description |
|---|
BuiltResponse() |
BuiltResponse(int status,
Headers<java.lang.Object> metadata,
java.lang.Object entity,
java.lang.annotation.Annotation[] entityAnnotations) |
| Modifier and Type | Method and Description |
|---|---|
void |
abortIfClosed() |
void |
addMethodAnnotations(java.lang.annotation.Annotation[] methodAnnotations) |
boolean |
bufferEntity() |
void |
close() |
java.util.Set<java.lang.String> |
getAllowedMethods() |
java.lang.annotation.Annotation[] |
getAnnotations() |
java.util.Map<java.lang.String,javax.ws.rs.core.NewCookie> |
getCookies() |
java.util.Date |
getDate() |
java.lang.Object |
getEntity() |
java.lang.Class |
getEntityClass() |
javax.ws.rs.core.EntityTag |
getEntityTag() |
java.lang.reflect.Type |
getGenericType() |
java.lang.String |
getHeaderString(java.lang.String name) |
protected HeaderValueProcessor |
getHeaderValueProcessor() |
java.util.Locale |
getLanguage() |
java.util.Date |
getLastModified() |
int |
getLength() |
javax.ws.rs.core.Link |
getLink(java.lang.String relation) |
javax.ws.rs.core.Link.Builder |
getLinkBuilder(java.lang.String relation) |
protected LinkHeaders |
getLinkHeaders() |
java.util.Set<javax.ws.rs.core.Link> |
getLinks() |
java.net.URI |
getLocation() |
javax.ws.rs.core.MediaType |
getMediaType() |
javax.ws.rs.core.MultivaluedMap<java.lang.String,java.lang.Object> |
getMetadata() |
int |
getStatus() |
javax.ws.rs.core.Response.StatusType |
getStatusInfo() |
javax.ws.rs.core.MultivaluedMap<java.lang.String,java.lang.String> |
getStringHeaders() |
boolean |
hasEntity() |
boolean |
hasLink(java.lang.String relation) |
boolean |
isClosed() |
<T> T |
readEntity(java.lang.Class<T> type) |
<T> T |
readEntity(java.lang.Class<T> type,
java.lang.annotation.Annotation[] annotations) |
<T> T |
readEntity(java.lang.Class<T> type,
java.lang.reflect.Type genericType,
java.lang.annotation.Annotation[] anns) |
<T> T |
readEntity(javax.ws.rs.core.GenericType<T> entityType) |
<T> T |
readEntity(javax.ws.rs.core.GenericType<T> entityType,
java.lang.annotation.Annotation[] annotations) |
void |
setAnnotations(java.lang.annotation.Annotation[] annotations) |
void |
setEntity(java.lang.Object entity) |
void |
setEntityClass(java.lang.Class entityClass) |
void |
setGenericType(java.lang.reflect.Type genericType) |
void |
setMetadata(javax.ws.rs.core.MultivaluedMap<java.lang.String,java.lang.Object> metadata) |
void |
setStatus(int status) |
protected java.lang.String |
toHeaderString(java.lang.Object header) |
protected java.lang.Object entity
protected int status
protected Headers<java.lang.Object> metadata
protected java.lang.annotation.Annotation[] annotations
protected java.lang.Class entityClass
protected java.lang.reflect.Type genericType
protected HeaderValueProcessor processor
protected boolean isClosed
public BuiltResponse()
public BuiltResponse(int status,
Headers<java.lang.Object> metadata,
java.lang.Object entity,
java.lang.annotation.Annotation[] entityAnnotations)
public java.lang.Class getEntityClass()
public void setEntityClass(java.lang.Class entityClass)
protected HeaderValueProcessor getHeaderValueProcessor()
public java.lang.Object getEntity()
getEntity in class javax.ws.rs.core.Responsepublic int getStatus()
getStatus in class javax.ws.rs.core.Responsepublic javax.ws.rs.core.Response.StatusType getStatusInfo()
getStatusInfo in class javax.ws.rs.core.Responsepublic javax.ws.rs.core.MultivaluedMap<java.lang.String,java.lang.Object> getMetadata()
getMetadata in class javax.ws.rs.core.Responsepublic void setEntity(java.lang.Object entity)
public void setStatus(int status)
public void setMetadata(javax.ws.rs.core.MultivaluedMap<java.lang.String,java.lang.Object> metadata)
public java.lang.annotation.Annotation[] getAnnotations()
public void addMethodAnnotations(java.lang.annotation.Annotation[] methodAnnotations)
public void setAnnotations(java.lang.annotation.Annotation[] annotations)
public java.lang.reflect.Type getGenericType()
public void setGenericType(java.lang.reflect.Type genericType)
public <T> T readEntity(java.lang.Class<T> type,
java.lang.annotation.Annotation[] annotations)
readEntity in class javax.ws.rs.core.Responsepublic <T> T readEntity(javax.ws.rs.core.GenericType<T> entityType,
java.lang.annotation.Annotation[] annotations)
readEntity in class javax.ws.rs.core.Responsepublic <T> T readEntity(java.lang.Class<T> type)
readEntity in class javax.ws.rs.core.Responsepublic <T> T readEntity(javax.ws.rs.core.GenericType<T> entityType)
readEntity in class javax.ws.rs.core.Responsepublic <T> T readEntity(java.lang.Class<T> type,
java.lang.reflect.Type genericType,
java.lang.annotation.Annotation[] anns)
public boolean hasEntity()
hasEntity in class javax.ws.rs.core.Responsepublic boolean bufferEntity()
bufferEntity in class javax.ws.rs.core.Responsepublic boolean isClosed()
public void abortIfClosed()
public void close()
close in class javax.ws.rs.core.Responsepublic java.util.Locale getLanguage()
getLanguage in class javax.ws.rs.core.Responsepublic int getLength()
getLength in class javax.ws.rs.core.Responsepublic javax.ws.rs.core.MediaType getMediaType()
getMediaType in class javax.ws.rs.core.Responsepublic java.util.Map<java.lang.String,javax.ws.rs.core.NewCookie> getCookies()
getCookies in class javax.ws.rs.core.Responsepublic javax.ws.rs.core.EntityTag getEntityTag()
getEntityTag in class javax.ws.rs.core.Responsepublic java.util.Date getDate()
getDate in class javax.ws.rs.core.Responsepublic java.util.Date getLastModified()
getLastModified in class javax.ws.rs.core.Responsepublic java.util.Set<java.lang.String> getAllowedMethods()
getAllowedMethods in class javax.ws.rs.core.Responseprotected java.lang.String toHeaderString(java.lang.Object header)
public javax.ws.rs.core.MultivaluedMap<java.lang.String,java.lang.String> getStringHeaders()
getStringHeaders in class javax.ws.rs.core.Responsepublic java.lang.String getHeaderString(java.lang.String name)
getHeaderString in class javax.ws.rs.core.Responsepublic java.net.URI getLocation()
getLocation in class javax.ws.rs.core.Responsepublic java.util.Set<javax.ws.rs.core.Link> getLinks()
getLinks in class javax.ws.rs.core.Responseprotected LinkHeaders getLinkHeaders()
public boolean hasLink(java.lang.String relation)
hasLink in class javax.ws.rs.core.Responsepublic javax.ws.rs.core.Link getLink(java.lang.String relation)
getLink in class javax.ws.rs.core.Responsepublic javax.ws.rs.core.Link.Builder getLinkBuilder(java.lang.String relation)
getLinkBuilder in class javax.ws.rs.core.Response