Documentation
¶
Index ¶
- func IsGrpcError(err error) bool
- type GrpcErr
- func NewGrpcApiError(code int, message string, details map[string]string) GrpcErr
- func NewGrpcApplicationError(code int, message string, details map[string]string) GrpcErr
- func NewGrpcBadRequestError(code int, message string, details map[string]string) GrpcErr
- func NewGrpcConflictError(code int, message string, details map[string]string) GrpcErr
- func NewGrpcDomainError(code int, message string, details map[string]string) GrpcErr
- func NewGrpcError(status codes.Code, code int, title string, message string, ...) GrpcErr
- func NewGrpcForbiddenError(code int, message string, details map[string]string) GrpcErr
- func NewGrpcInternalServerError(code int, message string, details map[string]string) GrpcErr
- func NewGrpcNotFoundError(code int, message string, details map[string]string) GrpcErr
- func NewGrpcUnAuthorizedError(code int, message string, details map[string]string) GrpcErr
- func NewGrpcValidationError(code int, message string, details map[string]string) GrpcErr
- func ParseError(err error) GrpcErr
- func ParseExternalGrpcErr(err error) GrpcErr
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func IsGrpcError ¶
Types ¶
type GrpcErr ¶
type GrpcErr interface { GetStatus() codes.Code SetStatus(status codes.Code) GrpcErr GetCode() int SetCode(code int) GrpcErr GetTitle() string SetTitle(title string) GrpcErr GetMsg() string SetMsg(msg string) GrpcErr GetDetails() map[string]string SetDetails(details map[string]string) GrpcErr GetTimestamp() time.Time SetTimestamp(time time.Time) GrpcErr Error() string ErrBody() error ToGrpcResponseErr() error }
func NewGrpcApiError ¶
func NewGrpcApplicationError ¶
func NewGrpcBadRequestError ¶
func NewGrpcConflictError ¶
func NewGrpcDomainError ¶
func NewGrpcError ¶
func NewGrpcForbiddenError ¶
func NewGrpcNotFoundError ¶
func NewGrpcValidationError ¶
func ParseError ¶
func ParseExternalGrpcErr ¶
Click to show internal directories.
Click to hide internal directories.