package
0.1.3
Repository: https://github.com/monadicstack/abide.git
Documentation: pkg.go.dev

# Functions

AlreadyExists is a 409-style error that is used when attempting to create some record/resource, but there is already a duplicate instance in existence.
BadCredentials is a 401-style error that indicates that the caller either didn't provide credentials when necessary or they did, but the credentials were invalid for some reason.
BadGateway is a 502-style error that indicates that some upstream resource was not available.
BadRequest is a 400-style error that indicates that some aspect of the request was either ill-formed or failed validation.
Gone is a 410-style error that is used to indicate that something used to exist, but doesn't anymore.
InternalServerError is a generic 500-style catch-all error for failures you don't know what to do with.
IsAlreadyExists returns true if the underlying HTTP status code of 'err' is 409.
IsBadCredentials returns true if the underlying HTTP status code of 'err' is 401.
IsBadGateway returns true if the underlying HTTP status code of 'err' is 502.
IsBadRequest returns true if the underlying HTTP status code of 'err' is 400.
IsGone returns true if the underlying HTTP status code of 'err' is 410.
IsInternalServiceError returns true if the underlying HTTP status code of 'err' is 500.
IsMethodNotAllowed returns true if the underlying HTTP status code of 'err' is 405.
IsNotFound returns true if the underlying HTTP status code of 'err' is 404.
IsNotImplemented returns true if the underlying HTTP status code of 'err' is 501.
IsPaymentRequired returns true if the underlying HTTP status code of 'err' is 402.
IsPermissionDenied returns true if the underlying HTTP status code of 'err' is 403.
IsThrottled returns true if the underlying HTTP status code of 'err' is 429.
IsTimeout returns true if the underlying HTTP status code of 'err' is 408.
IsTooLarge returns true if the underlying HTTP status code of 'err' is 413.
IsUnavailable returns true if the underlying HTTP status code of 'err' is 503.
IsUnexpected returns true if the underlying HTTP status code of 'err' is 500.
IsUnsupportedFormat returns true if the underlying HTTP status code of 'err' is 415.
MethodNotAllowed is a 405-style error that indicates that the wrong HTTP method was used.
New creates an error that maps directly to an HTTP status so if your method results in this error, it will result in the same 'status' in your HTTP response.
NewGroup returns a new Group and an associated Context derived from ctx.
NotFound is a 404-style error that indicates that some record/resource could not be located.
NotImplemented is a 501-style error that indicates that the resource/logic required to fulfill the request has not been added yet.
PaymentRequired is a 402-style error that indicates that you must provide payment to access the given resource or perform the given task.
PermissionDenied is a 403-style error that indicates that the caller does not have rights/clearance to perform any part of the operation.
Status looks for either a Status(), StatusCode(), or Code() method on the error to figure out the most appropriate HTTP status code for it.
Throttled is a 429-style error that indicates that the caller has exceeded the number of requests, amount of resources, etc allowed over some time period.
Timeout is a 408-style error that indicates that some operation exceeded its allotted time/deadline.
TooLarge is a 413-style error that is used to indicate that some resource/entity is too big.
Unavailable is a 503-style error that indicates that some aspect of the server/service is unavailable.
Unexpected is a generic 500-style catch-all error for failures you don't know what to do with.
UnsupportedFormat is a 415-style error that is used to indicate that the media/content type of some input is not valid.

# Structs

A Group is a collection of goroutines working on subtasks that are part of the same overall task.
StatusError is an error that maintains not just an error message but an HTTP compatible status code indicating the type/class of error.

# Type aliases

ErrorHandler is the generic function signature for something that accepts errors that occur in the bowels of the framework.