diff options
author | Maxim Lebedev <toby3d@yandex.com> | 2019-05-06 20:54:49 +0500 |
---|---|---|
committer | Erik Dubbelboer <erik@dubbelboer.com> | 2019-05-06 17:54:49 +0200 |
commit | f544170d6384e251aa6657e55bac36c999c86e7a (patch) | |
tree | e55dc8af183dfe5e22a2191f96460ab75282a019 /methods.go | |
parent | Timing fixes (#564) (diff) | |
download | fasthttp-f544170d6384e251aa6657e55bac36c999c86e7a.tar.gz fasthttp-f544170d6384e251aa6657e55bac36c999c86e7a.tar.bz2 fasthttp-f544170d6384e251aa6657e55bac36c999c86e7a.zip |
Added methods constants (#567)
* :sparkles: Added methods constants
* :ok_hand: Fixed methods comment due to review changes
Diffstat (limited to 'methods.go')
-rw-r--r-- | methods.go | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/methods.go b/methods.go new file mode 100644 index 0000000..a614584 --- /dev/null +++ b/methods.go @@ -0,0 +1,14 @@ +package fasthttp + +// HTTP methods were copied from net/http. +const ( + MethodGet = "GET" // RFC 7231, 4.3.1 + MethodHead = "HEAD" // RFC 7231, 4.3.2 + MethodPost = "POST" // RFC 7231, 4.3.3 + MethodPut = "PUT" // RFC 7231, 4.3.4 + MethodPatch = "PATCH" // RFC 5789 + MethodDelete = "DELETE" // RFC 7231, 4.3.5 + MethodConnect = "CONNECT" // RFC 7231, 4.3.6 + MethodOptions = "OPTIONS" // RFC 7231, 4.3.7 + MethodTrace = "TRACE" // RFC 7231, 4.3.8 +) |