request

package
v0.0.0-...-41c7706 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 29, 2022 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CheckNeedArgs

func CheckNeedArgs(values url.Values, args ...string) error

func DealGetError

func DealGetError()

func DealPostError

func DealPostError()

Types

type Dealer

type Dealer struct {
	Header   func(w http.ResponseWriter) `json:"header"`
	Handlers []Handler                   `json:"handlers"`
}

func (Dealer) Deal

type GetRequest

type GetRequest struct {
	Query url.Values `json:"query"`
	Err   error      `json:"err"`
}

func DealGetRequest

func DealGetRequest(w http.ResponseWriter, r *http.Request, args ...string) GetRequest

type Handler

type Handler interface {
	Dealer(w http.ResponseWriter, r *http.Request) (http.ResponseWriter, *http.Request, error)
}

type PostRequest

type PostRequest struct {
	Err error `json:"err"`
}

func DealPostRequest

func DealPostRequest(w http.ResponseWriter, r *http.Request, args ...string) PostRequest

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL