grapql_api

package
v0.0.11 Latest Latest
Warning

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

Go to latest
Published: Feb 17, 2024 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ErrorHandler

type ErrorHandler struct {
	CustomGetMessage func(err validator.FieldError) string
	// contains filtered or unexported fields
}

func NewErrorHandler

func NewErrorHandler(ctx context.Context) ErrorHandler

func NewErrorHandlerWithCustomMessages

func NewErrorHandlerWithCustomMessages(ctx context.Context, msgGetter func(err validator.FieldError) string) ErrorHandler

func (ErrorHandler) AddFieldErrorToResponse

func (e ErrorHandler) AddFieldErrorToResponse(field string, message string) error

func (ErrorHandler) AddValidationsErrors

func (e ErrorHandler) AddValidationsErrors(err error) error

Jump to

Keyboard shortcuts

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