httputil

package
v0.6.0 Latest Latest
Warning

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

Go to latest
Published: Feb 24, 2024 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AllowCORS

func AllowCORS(w http.ResponseWriter, r *http.Request, allowMethods []string, allowCredentials bool)

func Cache added in v0.3.0

func Cache(w http.ResponseWriter, duration time.Duration)

func ExtractAccessToken

func ExtractAccessToken(r *http.Request) string

func NoCache

func NoCache(w http.ResponseWriter)

func RedirectFragment

func RedirectFragment(w http.ResponseWriter, r *http.Request, url string, params url.Values)

func RedirectQuery

func RedirectQuery(w http.ResponseWriter, r *http.Request, url string, params url.Values)

Types

type Timing

type Timing struct {
	// contains filtered or unexported fields
}

func NewTiming

func NewTiming() *Timing

func (Timing) Report

func (t Timing) Report(w http.ResponseWriter)

func (*Timing) Start

func (t *Timing) Start(name string)

func (*Timing) Stop

func (t *Timing) Stop(name string)

Jump to

Keyboard shortcuts

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