mindiaerr

package
v0.0.1 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ApiError

type ApiError struct {
	RawMessage string `json:"message"`
	Code       string `json:"code"`
}

func NewApiError

func NewApiError(err Error) *ApiError

type ErrCode

type ErrCode int
const (
	ErrCodeUnknown       ErrCode = 0
	ErrCodeMediaNotFound ErrCode = iota + 1
	ErrCodeApiKeyNotFound
	ErrBadRequest
	ErrCodeInternal
	ErrCodeMimeTypeNotSupported
	ErrCodeNamedTransformationNotFound
	ErrCodeTransformationNotFound
	ErrCodeUnauthorizedRequest
	ErrCodeServiceUnavailable
)

func (ErrCode) Code

func (e ErrCode) Code() string

func (ErrCode) RawMessage

func (e ErrCode) RawMessage() string

type Error

type Error struct {
	ErrCode ErrCode
	Msg     error
}

func New

func New(errCode ErrCode) *Error

func (*Error) Error

func (e *Error) Error() string

Jump to

Keyboard shortcuts

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