handler

package
v0.2.39 Latest Latest
Warning

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

Go to latest
Published: Jul 24, 2023 License: Apache-2.0, MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DownloadHandler

func DownloadHandler(ctx context.Context,
	piece string,
	api string,
	config map[string]string,
	outDir string,
	concurrency int,
) error

Types

type Error

type Error struct {
	Err            error
	HTTPStatusCode int
}

func NewBadRequestError

func NewBadRequestError(err error) *Error

func NewBadRequestString

func NewBadRequestString(err string) *Error

func NewHTTPError added in v0.2.8

func NewHTTPError(code int, err string) *Error

func NewHandlerError

func NewHandlerError(err error) *Error

func (*Error) Error

func (e *Error) Error() string

func (*Error) HTTPResponse added in v0.2.8

func (e *Error) HTTPResponse(c echo.Context) error

type HTTPError

type HTTPError struct {
	Err string `json:"err"`
}

Directories

Path Synopsis
Code generated.
Code generated.

Jump to

Keyboard shortcuts

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