types

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Aug 30, 2022 License: GPL-3.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AuthInter

type AuthInter interface {
	Format(p any) error
}

type BasicAuth

type BasicAuth struct {
	Username string
	Password string
}

func (BasicAuth) Format

func (a BasicAuth) Format(p any) error

type BearerAuth

type BearerAuth struct {
	Token string
}

func (BearerAuth) Format

func (a BearerAuth) Format(p any) error

type Dict

type Dict map[string]string

type Ext

type Ext func(ep *ExtensionPackage)

type ExtensionPackage

type ExtensionPackage struct {
	Method         string // 隐性参数
	Url            string // 直传参数
	AllowRedirects bool   // 以下均为扩展参数
	Auth           AuthInter
	Cookies        Dict
	Data           Dict
	Files          Dict
	Headers        Dict
	Hooks          HooksDict
	Json           map[string]any
	Params         Dict
	Proxy          string
	Stream         io.Reader
	Timeout        int
	Verify         bool
}

type Hook

type Hook func(object any) (error, any)

type HooksDict

type HooksDict map[string][]Hook

type Json

type Json map[string]any

type List

type List []string

Jump to

Keyboard shortcuts

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