|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.commons.httpclient.HttpMethodBase org.apache.commons.httpclient.methods.OptionsMethod
public class OptionsMethod
Implements the HTTP OPTIONS method.
The HTTP OPTIONS method is defined in section 9.2 of RFC2616:
The OPTIONS method represents a request for information about the communication options available on the request/response chain identified by the Request-URI. This method allows the client to determine the options and/or requirements associated with a resource, or the capabilities of a server, without implying a resource action or initiating a resource retrieval.
Field Summary |
---|
Fields inherited from class org.apache.commons.httpclient.HttpMethodBase |
---|
effectiveVersion, statusLine |
Constructor Summary | |
---|---|
OptionsMethod()
Method constructor. |
|
OptionsMethod(String uri)
Constructor specifying a URI. |
Method Summary | |
---|---|
Enumeration |
getAllowedMethods()
Get a list of allowed methods. |
String |
getName()
Get the name. |
boolean |
isAllowed(String method)
Is the specified method allowed ? |
boolean |
needContentLength()
Deprecated. only entity enclosing methods set content length header |
protected void |
processResponseHeaders(HttpState state,
HttpConnection conn)
This implementation will parse the Allow header to obtain the set of methods supported by the resource identified by the Request-URI. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public OptionsMethod()
public OptionsMethod(String uri)
uri
- either an absolute or relative URIMethod Detail |
---|
public String getName()
getName
in interface HttpMethod
getName
in class HttpMethodBase
public boolean isAllowed(String method)
method
- The method to check.
public Enumeration getAllowedMethods()
protected void processResponseHeaders(HttpState state, HttpConnection conn)
This implementation will parse the Allow header to obtain the set of methods supported by the resource identified by the Request-URI.
processResponseHeaders
in class HttpMethodBase
state
- the state
information associated with this methodconn
- the connection
used to execute
this HTTP methodHttpMethodBase.readResponse(org.apache.commons.httpclient.HttpState, org.apache.commons.httpclient.HttpConnection)
,
HttpMethodBase.readResponseHeaders(org.apache.commons.httpclient.HttpState, org.apache.commons.httpclient.HttpConnection)
public boolean needContentLength()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |