response

package
v1.4.6 Latest Latest
Warning

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

Go to latest
Published: Feb 24, 2022 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Pass             = 0
	Deny             = 1
	Error            = 2
	AccountDisabled  = 10000
	IllegalRequest   = 10001
	NamespaceInvalid = 10002
	IllegalParam     = 10003
	LoginExpired     = 10086
)

response code

Variables

This section is empty.

Functions

This section is empty.

Types

type Empty

type Empty struct{}

func (Empty) Write

func (Empty) Write(http.ResponseWriter) error

JSON response

type File added in v1.4.5

type File struct {
	Filename string
}

func (File) Write added in v1.4.5

func (f File) Write(w http.ResponseWriter) error

JSON response

type JSON

type JSON struct {
	Code    int         `json:"code"`
	Message string      `json:"message"`
	Data    interface{} `json:"data"`
}

func (JSON) Write

func (j JSON) Write(w http.ResponseWriter) error

JSON response

type SftpFile

type SftpFile struct {
	Client      *ssh.Client
	Filename    string
	Disposition string // attachment | inline
}

func (SftpFile) Write

func (sf SftpFile) Write(w http.ResponseWriter) error

JSON response

Jump to

Keyboard shortcuts

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