main.go 422 B

123456789101112131415161718192021222324
  1. package methods
  2. import (
  3. "net/http"
  4. )
  5. type Method string
  6. const (
  7. Get Method = http.MethodGet
  8. Post Method = http.MethodPost
  9. Put Method = http.MethodPut
  10. Head Method = http.MethodHead
  11. Patch Method = http.MethodPatch
  12. Delete Method = http.MethodDelete
  13. Connect Method = http.MethodConnect
  14. Options Method = http.MethodOptions
  15. Trace Method = http.MethodTrace
  16. )
  17. func (m Method) String() string {
  18. return string(m)
  19. }