|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.sun.ws.rest.api.response.HttpResponse com.sun.ws.rest.api.response.Created
public class Created
An abstraction for a response to a request that resulted in the creation of a new resource,
Constructor Summary | |
---|---|
Created(Representation<?> r)
Create a new instance. |
|
Created(Representation<?> r,
java.net.URI location)
Create a new instance |
|
Created(java.net.URI location)
Create a new instance |
Method Summary | |
---|---|
void |
addResponseHeaders(HttpContext context)
Add the HTTP headers for this type of response to the response context. |
java.net.URI |
getLocation()
Get the location of a newly created resource. |
void |
setLocation(java.net.URI location)
Set the location of a newly created resource. |
Methods inherited from class com.sun.ws.rest.api.response.HttpResponse |
---|
getCacheControl, getCacheControl, getRepresentation, getStatus, setRepresentation, setStatus |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Created(java.net.URI location)
location
- an absolute or relative URI that identifies the newly
created resource. Relative URIs are relative to the request
URI.public Created(Representation<?> r)
r
- a representation of the newly created resourcepublic Created(Representation<?> r, java.net.URI location)
r
- a representation of the newly created resourcelocation
- an absolute or relative URI that identifies the newly
created resource. Relative URIs are relative to the request
URI.Method Detail |
---|
public void setLocation(java.net.URI location)
location
- the URI of the newly created resource. Relative URIs
are allowed, the runtime will resolve such URIs against the URI of the
resource whose method returned the representation.public java.net.URI getLocation()
public void addResponseHeaders(HttpContext context)
addResponseHeaders
in class HttpResponse
context
- the current HTTP context
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |