storage

package
v0.0.0-...-eee2b2e Latest Latest
Warning

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

Go to latest
Published: Jul 9, 2020 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrInvalidInputData = errors.New("invalid input data")
	ErrRequestNotFound  = errors.New("request not found")
)

Functions

This section is empty.

Types

type Storage

type Storage interface {
	// AddFetchData saves fetch data and return ID.
	AddRequest(data *model.FetchData) (string, error)

	// AddResponse saves response from external resource by request ID.
	AddResponse(ID string, response *model.Response) error

	// GetAllRequests reads all requests from storage.
	GetAllRequests(paginator *model.Paginator) []model.Request

	// DeleteRequest removes request from storage by ID.
	DeleteRequest(ID string) error
}

Storage for application requests.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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