Top Description Inners Fields Constructors Methods
org.eclipse.jetty.http

public final Enum HttpMethod

extends Enum<HttpMethod>
Class Inheritance
Imports
java.nio.ByteBuffer, org.eclipse.jetty.util.Index, .StringUtil

Known HTTP Methods

Nested and Inner Type Summary

Modifier and TypeClass and Description
private static enum

Field Summary

Modifier and TypeField and Description
private final ByteBuffer
private final byte[]
private final String
private final HttpMethod.Type
public static final HttpMethod
public static final int
public static final HttpMethod
public static final HttpMethod
public static final Index<HttpMethod>
public static final HttpMethod
public static final HttpMethod
public static final HttpMethod
public static final HttpMethod
public static final HttpMethod
public static final HttpMethod
public static final int
public static final HttpMethod
public static final int
public static final Index<HttpMethod>
public static final HttpMethod
public static final HttpMethod
public static final HttpMethod
public static final Index<HttpMethod>
public static final HttpMethod
public static final HttpMethod
public static final HttpMethod
public static final HttpMethod
public static final HttpMethod
public static final HttpMethod
public static final HttpMethod
public static final HttpMethod
public static final HttpMethod
public static final HttpMethod
public static final HttpMethod
public static final int
public static final HttpMethod
public static final int
public static final HttpMethod
public static final HttpMethod
public static final HttpMethod
public static final HttpMethod
public static final int
public static final HttpMethod
public static final HttpMethod
public static final HttpMethod
public static final HttpMethod
public static final HttpMethod
public static final HttpMethod
public static final HttpMethod
public static final HttpMethod
public static final HttpMethod
public static final HttpMethod
public static final HttpMethod

Constructor Summary

AccessConstructor and Description
private

Method Summary

Modifier and TypeMethod and Description
public ByteBuffer
public String
public static HttpMethod

Returns:

the HttpMethod or null if the parameter method is unknown
fromString
(String
the String to get the equivalent HttpMethod from
method
)

Converts the given String parameter to an HttpMethod.

public byte[]
public boolean
public boolean

Returns:

true if the method is idempotent.
isIdempotent
()

An idempotent HTTP method is an HTTP method that can be called many times without different outcomes.

public boolean

Returns:

if the method is safe.
isSafe
()

An HTTP method is safe if it doesn't alter the state of the server.

public static HttpMethod

Returns:

An HttpMethod if a match or null if no easy match.
lookAheadGet
(ByteBuffer
buffer containing ISO-8859-1 characters, it is not modified.
buffer
)

Optimized lookup to find a method name and trailing space in a byte array.

public String
toString()

Overrides java.lang.Enum.toString.

Returns the name of this enum constant, as contained in the declaration.

public static HttpMethod
public static HttpMethod[]
Inherited from java.lang.Enum:
clonecompareTodescribeConstableequalsfinalizegetDeclaringClasshashCodenameordinalvalueOf

Field Detail

_bufferback to summary
private final ByteBuffer _buffer
_bytesback to summary
private final byte[] _bytes
_methodback to summary
private final String _method
_typeback to summary
private final HttpMethod.Type _type
ACLback to summary
public static final HttpMethod ACL
ACL_AS_INTback to summary
public static final int ACL_AS_INT
BASELINE_CONTROLback to summary
public static final HttpMethod BASELINE_CONTROL
BINDback to summary
public static final HttpMethod BIND
CACHEback to summary
public static final Index<HttpMethod> CACHE
CHECKINback to summary
public static final HttpMethod CHECKIN
CHECKOUTback to summary
public static final HttpMethod CHECKOUT
CONNECTback to summary
public static final HttpMethod CONNECT
COPYback to summary
public static final HttpMethod COPY
DELETEback to summary
public static final HttpMethod DELETE
GETback to summary
public static final HttpMethod GET
GET_AS_INTback to summary
public static final int GET_AS_INT
HEAD_AS_INTback to summary
public static final int HEAD_AS_INT
INSENSITIVE_CACHEback to summary
public static final Index<HttpMethod> INSENSITIVE_CACHE
LABELback to summary
public static final HttpMethod LABEL
LOCKback to summary
public static final HttpMethod LOCK
LOOK_AHEADback to summary
public static final Index<HttpMethod> LOOK_AHEAD
MERGEback to summary
public static final HttpMethod MERGE
MKACTIVITYback to summary
public static final HttpMethod MKACTIVITY
MKCALENDARback to summary
public static final HttpMethod MKCALENDAR
MKCOLback to summary
public static final HttpMethod MKCOL
MKREDIRECTREFback to summary
public static final HttpMethod MKREDIRECTREF
MKWORKSPACEback to summary
public static final HttpMethod MKWORKSPACE
MOVEback to summary
public static final HttpMethod MOVE
OPTIONSback to summary
public static final HttpMethod OPTIONS
ORDERPATCHback to summary
public static final HttpMethod ORDERPATCH
PATCHback to summary
public static final HttpMethod PATCH
POSTback to summary
public static final HttpMethod POST
POST_AS_INTback to summary
public static final int POST_AS_INT
PRIback to summary
public static final HttpMethod PRI
PRI_AS_INTback to summary
public static final int PRI_AS_INT
PROPFINDback to summary
public static final HttpMethod PROPFIND
PROPPATCHback to summary
public static final HttpMethod PROPPATCH
PROXYback to summary
public static final HttpMethod PROXY
PUTback to summary
public static final HttpMethod PUT
PUT_AS_INTback to summary
public static final int PUT_AS_INT
REBINDback to summary
public static final HttpMethod REBIND
REPORTback to summary
public static final HttpMethod REPORT
TRACEback to summary
public static final HttpMethod TRACE
UNBINDback to summary
public static final HttpMethod UNBIND
UNCHECKOUTback to summary
public static final HttpMethod UNCHECKOUT
UNLOCKback to summary
public static final HttpMethod UNLOCK
UPDATEback to summary
public static final HttpMethod UPDATE
UPDATEREDIRECTREFback to summary
public static final HttpMethod UPDATEREDIRECTREF
VERSION_CONTROLback to summary
public static final HttpMethod VERSION_CONTROL

Constructor Detail

HttpMethodback to summary
private HttpMethod(HttpMethod.Type type)

Method Detail

asBufferback to summary
public ByteBuffer asBuffer()
asStringback to summary
public String asString()
fromStringback to summary
public static HttpMethod fromString(String method)

Converts the given String parameter to an HttpMethod. The string may differ from the Enum name as a '-' in the method name is represented as a '_' in the Enum name.

Parameters
method:String

the String to get the equivalent HttpMethod from

Returns:HttpMethod

the HttpMethod or null if the parameter method is unknown

getBytesback to summary
public byte[] getBytes()
isback to summary
public boolean is(String s)
isIdempotentback to summary
public boolean isIdempotent()

An idempotent HTTP method is an HTTP method that can be called many times without different outcomes. It would not matter if the method is called only once, or ten times over. The result should be the same.

Returns:boolean

true if the method is idempotent.

isSafeback to summary
public boolean isSafe()

An HTTP method is safe if it doesn't alter the state of the server. In other words, a method is safe if it leads to a read-only operation. Several common HTTP methods are safe: GET , HEAD , or OPTIONS . All safe methods are also idempotent, but not all idempotent methods are safe

Returns:boolean

if the method is safe.

lookAheadGetback to summary
public static HttpMethod lookAheadGet(ByteBuffer buffer)

Optimized lookup to find a method name and trailing space in a byte array.

Parameters
buffer:ByteBuffer

buffer containing ISO-8859-1 characters, it is not modified.

Returns:HttpMethod

An HttpMethod if a match or null if no easy match.

toStringback to summary
public String toString()

Overrides java.lang.Enum.toString.

Doc from java.lang.Enum.toString.

Returns the name of this enum constant, as contained in the declaration. This method may be overridden, though it typically isn't necessary or desirable. An enum class should override this method when a more "programmer-friendly" string form exists.

Returns:String

the name of this enum constant

valueOfback to summary
public static HttpMethod valueOf(String name)
valuesback to summary
public static HttpMethod[] values()
org.eclipse.jetty.http back to summary

private final Enum HttpMethod.Type

extends Enum<HttpMethod.Type>
Class Inheritance

Field Summary

Modifier and TypeField and Description
public static final HttpMethod.Type
public static final HttpMethod.Type
public static final HttpMethod.Type

Constructor Summary

AccessConstructor and Description
private
Type()

Method Summary

Modifier and TypeMethod and Description
public static HttpMethod.Type
public static HttpMethod.Type[]
Inherited from java.lang.Enum:
clonecompareTodescribeConstableequalsfinalizegetDeclaringClasshashCodenameordinaltoStringvalueOf

Field Detail

IDEMPOTENTback to summary
public static final HttpMethod.Type IDEMPOTENT
NORMALback to summary
public static final HttpMethod.Type NORMAL
SAFEback to summary
public static final HttpMethod.Type SAFE

Constructor Detail

Typeback to summary
private Type()

Method Detail

valueOfback to summary
public static HttpMethod.Type valueOf(String name)
valuesback to summary
public static HttpMethod.Type[] values()