Structure
Abort
Default implementation of
AbortError. You can use this as a convenient method for throwing AbortErrors without having to conform your own error-type to AbortError.struct Abort
Overview
throw Abort(.badRequest, reason: "Something's not quite right...")
Topics
Initializers
init(HTTPResponse.Status, headers: HTTPFields, reason: String?, identifier: String?, suggestedFixes: [String], file: String, function: String, line: UInt, column: UInt, range: Range<UInt>?)Create a newAbort, capturing current source location info.
Instance Properties
var headers: HTTPFieldsvar identifier: Stringvar reason: Stringvar source: ErrorSource?Source location where this error was created.var status: HTTPResponse.Status
Type Methods
static func redirect(to: String, redirectType: Redirect) -> AbortCreates a redirectingAborterror.
Relationships
Conforms To
AbortErrorDebuggableErrorFoundationEssentials.LocalizedErrorSwift.CustomDebugStringConvertibleSwift.CustomStringConvertibleSwift.EquatableSwift.ErrorSwift.SendableSwift.SendableMetatype