httptools

package
v0.0.13 Latest Latest
Warning

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

Go to latest
Published: Mar 31, 2020 License: MIT Imports: 8 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func TemplateAddFunc added in v0.0.13

func TemplateAddFunc(name string, fn interface{})

Types

type HTTPWriter

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

func NewHTTPWriter

func NewHTTPWriter(w http.ResponseWriter, r *http.Request) *HTTPWriter

func (*HTTPWriter) GetPath

func (this *HTTPWriter) GetPath() string

func (*HTTPWriter) HttpOnlyIs

func (this *HTTPWriter) HttpOnlyIs(methods ...string) bool

func (*HTTPWriter) NotFound

func (this *HTTPWriter) NotFound()

func (*HTTPWriter) Release

func (this *HTTPWriter) Release()

func (*HTTPWriter) SendHttpCode

func (this *HTTPWriter) SendHttpCode(code int)

func (*HTTPWriter) SendHttpRedirect

func (this *HTTPWriter) SendHttpRedirect(l string)

func (*HTTPWriter) SendHttpString

func (this *HTTPWriter) SendHttpString(s string)

func (*HTTPWriter) SendJSAlert

func (this *HTTPWriter) SendJSAlert(args ...string)

func (*HTTPWriter) TemplateFileWrite

func (this *HTTPWriter) TemplateFileWrite(path string, data interface{}) (bool, error)

func (*HTTPWriter) TemplateWrite

func (this *HTTPWriter) TemplateWrite(content []byte, data interface{}, ct string) (bool, error)

Jump to

Keyboard shortcuts

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