Documentation
¶
Index ¶
- Variables
- func As(err error, target interface{}) bool
- func Errorf(code codes.Code, format string, a ...interface{}) error
- func Is(err, target error) bool
- func New(code codes.Code, msg string) error
- func Unwrap(err error) error
- func Wrap(e error, msg string) error
- func Wrapf(e error, format string, a ...interface{}) error
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // ErrUnknown indicates an unknown error. Unknown = New(codes.Unknown, codes.Unknown.String()) // ErrInvalidArgument indicates missing or malformed field in a request. InvalidArgument = New(codes.InvalidArgument, codes.InvalidArgument.String()) // ErrNotFound indicates that the requested resource does not exist. NotFound = New(codes.NotFound, codes.NotFound.String()) // ErrAlreadyExists indicates that the request to be created already exits. AlreadyExists = New(codes.AlreadyExists, codes.AlreadyExists.String()) // ErrUnimplemented indicates the requested service has not been implemented. Unimplemented = New(codes.Unimplemented, codes.Unimplemented.String()) // Internal indicates an internal errors. Internal = New(codes.Internal, codes.Internal.String()) )
Functions ¶
func As ¶ added in v0.4.0
As arovides a local implementation of the standard errors function to allow users to import a single errors package.
func Is ¶ added in v0.4.0
Is provides a local implementation of the standard errors function to allow users to import a single errors package.
func Unwrap ¶ added in v0.4.0
Unwrap provides a local implementation of the standard errors function to allow users to import a single errors package.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.