public class OutboundJaxrsResponse
extends jakarta.ws.rs.core.Response
underlying
outbound message context
.Modifier and Type | Class and Description |
---|---|
static class |
OutboundJaxrsResponse.Builder
Outbound JAX-RS
Response.ResponseBuilder implementation. |
Constructor and Description |
---|
OutboundJaxrsResponse(jakarta.ws.rs.core.Response.StatusType status,
OutboundMessageContext context)
Create new outbound JAX-RS response message instance.
|
Modifier and Type | Method and Description |
---|---|
boolean |
bufferEntity() |
void |
close() |
static OutboundJaxrsResponse |
from(jakarta.ws.rs.core.Response response)
Deprecated.
|
static OutboundJaxrsResponse |
from(jakarta.ws.rs.core.Response response,
jakarta.ws.rs.core.Configuration configuration)
Get an OutboundJaxrsResponse instance for a given JAX-RS response.
|
Set<String> |
getAllowedMethods() |
OutboundMessageContext |
getContext()
Get the underlying outbound message context.
|
Map<String,jakarta.ws.rs.core.NewCookie> |
getCookies() |
Date |
getDate() |
Object |
getEntity() |
jakarta.ws.rs.core.EntityTag |
getEntityTag() |
String |
getHeaderString(String name) |
Locale |
getLanguage() |
Date |
getLastModified() |
int |
getLength() |
jakarta.ws.rs.core.Link |
getLink(String relation) |
jakarta.ws.rs.core.Link.Builder |
getLinkBuilder(String relation) |
Set<jakarta.ws.rs.core.Link> |
getLinks() |
URI |
getLocation() |
jakarta.ws.rs.core.MediaType |
getMediaType() |
jakarta.ws.rs.core.MultivaluedMap<String,Object> |
getMetadata() |
int |
getStatus() |
jakarta.ws.rs.core.Response.StatusType |
getStatusInfo() |
jakarta.ws.rs.core.MultivaluedMap<String,String> |
getStringHeaders() |
boolean |
hasEntity() |
boolean |
hasLink(String relation) |
<T> T |
readEntity(Class<T> type) |
<T> T |
readEntity(Class<T> type,
Annotation[] annotations) |
<T> T |
readEntity(jakarta.ws.rs.core.GenericType<T> entityType) |
<T> T |
readEntity(jakarta.ws.rs.core.GenericType<T> entityType,
Annotation[] annotations) |
String |
toString() |
public OutboundJaxrsResponse(jakarta.ws.rs.core.Response.StatusType status, OutboundMessageContext context)
status
- response status.context
- underlying outbound message context.public static OutboundJaxrsResponse from(jakarta.ws.rs.core.Response response, jakarta.ws.rs.core.Configuration configuration)
response
- response instance to from.configuration
- the related client/server side Configuration
. Can be null
.OutboundJaxrsResponse
instance.@Deprecated public static OutboundJaxrsResponse from(jakarta.ws.rs.core.Response response)
response
- response instance to from.OutboundJaxrsResponse
instance.from(Response, Configuration)
public OutboundMessageContext getContext()
public int getStatus()
getStatus
in class jakarta.ws.rs.core.Response
public jakarta.ws.rs.core.Response.StatusType getStatusInfo()
getStatusInfo
in class jakarta.ws.rs.core.Response
public Object getEntity()
getEntity
in class jakarta.ws.rs.core.Response
public <T> T readEntity(Class<T> type) throws jakarta.ws.rs.ProcessingException
readEntity
in class jakarta.ws.rs.core.Response
jakarta.ws.rs.ProcessingException
public <T> T readEntity(jakarta.ws.rs.core.GenericType<T> entityType) throws jakarta.ws.rs.ProcessingException
readEntity
in class jakarta.ws.rs.core.Response
jakarta.ws.rs.ProcessingException
public <T> T readEntity(Class<T> type, Annotation[] annotations) throws jakarta.ws.rs.ProcessingException
readEntity
in class jakarta.ws.rs.core.Response
jakarta.ws.rs.ProcessingException
public <T> T readEntity(jakarta.ws.rs.core.GenericType<T> entityType, Annotation[] annotations) throws jakarta.ws.rs.ProcessingException
readEntity
in class jakarta.ws.rs.core.Response
jakarta.ws.rs.ProcessingException
public boolean hasEntity()
hasEntity
in class jakarta.ws.rs.core.Response
public boolean bufferEntity() throws jakarta.ws.rs.ProcessingException
bufferEntity
in class jakarta.ws.rs.core.Response
jakarta.ws.rs.ProcessingException
public void close() throws jakarta.ws.rs.ProcessingException
close
in interface AutoCloseable
close
in class jakarta.ws.rs.core.Response
jakarta.ws.rs.ProcessingException
public jakarta.ws.rs.core.MultivaluedMap<String,String> getStringHeaders()
getStringHeaders
in class jakarta.ws.rs.core.Response
public String getHeaderString(String name)
getHeaderString
in class jakarta.ws.rs.core.Response
public jakarta.ws.rs.core.MediaType getMediaType()
getMediaType
in class jakarta.ws.rs.core.Response
public Locale getLanguage()
getLanguage
in class jakarta.ws.rs.core.Response
public int getLength()
getLength
in class jakarta.ws.rs.core.Response
public Map<String,jakarta.ws.rs.core.NewCookie> getCookies()
getCookies
in class jakarta.ws.rs.core.Response
public jakarta.ws.rs.core.EntityTag getEntityTag()
getEntityTag
in class jakarta.ws.rs.core.Response
public Date getDate()
getDate
in class jakarta.ws.rs.core.Response
public Date getLastModified()
getLastModified
in class jakarta.ws.rs.core.Response
public Set<String> getAllowedMethods()
getAllowedMethods
in class jakarta.ws.rs.core.Response
public URI getLocation()
getLocation
in class jakarta.ws.rs.core.Response
public Set<jakarta.ws.rs.core.Link> getLinks()
getLinks
in class jakarta.ws.rs.core.Response
public boolean hasLink(String relation)
hasLink
in class jakarta.ws.rs.core.Response
public jakarta.ws.rs.core.Link getLink(String relation)
getLink
in class jakarta.ws.rs.core.Response
public jakarta.ws.rs.core.Link.Builder getLinkBuilder(String relation)
getLinkBuilder
in class jakarta.ws.rs.core.Response
public jakarta.ws.rs.core.MultivaluedMap<String,Object> getMetadata()
getMetadata
in class jakarta.ws.rs.core.Response
Copyright © 2007-2021, Oracle and/or its affiliates. All Rights Reserved. Use is subject to license terms.