merror

package
v0.0.0-...-fb91958 Latest Latest
Warning

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

Go to latest
Published: Jul 20, 2025 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CodeFromError

func CodeFromError(err error) connect.Code

func IsAlreadyExists

func IsAlreadyExists(err error) bool

func IsCanceled

func IsCanceled(err error) bool

func IsFailedPrecondition

func IsFailedPrecondition(err error) bool

func IsInternal

func IsInternal(err error) bool

func IsInvalidArgument

func IsInvalidArgument(err error) bool

func IsNotFound

func IsNotFound(err error) bool

func NewAlreadyExists

func NewAlreadyExists(messageFormat string, args ...any) error

func NewCanceled

func NewCanceled(messageFormat string, args ...any) error

func NewFailedPrecondition

func NewFailedPrecondition(violationType string, messageFormat string, args ...any) error

func NewInternal

func NewInternal(messageFormat string, args ...any) error

func NewInvalidArgument

func NewInvalidArgument(fvs FieldViolations, messageFormat string, args ...any) error

func NewNotFound

func NewNotFound(messageFormat string, args ...any) error

func NewPermissionDenied

func NewPermissionDenied(messageFormat string, args ...any) error

func NewUnauthenticated

func NewUnauthenticated(messageFormat string, args ...any) error

func NewUnavailable

func NewUnavailable(messageFormat string, args ...any) error

func ViolationTypeFromError

func ViolationTypeFromError(e error) string

func WrapInternal

func WrapInternal(err error, messageFormat string, args ...any) error

Types

type FieldViolation

type FieldViolation struct {
	Field       string
	Description string
}

type FieldViolations

type FieldViolations []FieldViolation

Jump to

Keyboard shortcuts

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