AnyError

public struct AnyError : Error, CustomStringConvertible, LocalizedError, Equatable

Generic non-specific error.

Properties

  • A descrption of error.

    Declaration

    Swift

    public let description: String

Lifecycle

  • Initialize an instance.

    Declaration

    Swift

    public init(_ description: String)

    Parameters

    description

    A description of error.

  • Initialize an instance.

    Declaration

    Swift

    public init(_ other: Error)

    Parameters

    other

    An other error.

  • An unknown error.

    Declaration

    Swift

    public static var unknown: AnyError { get }

Conformance: LocalizedError

  • Declaration

    Swift

    public var errorDescription: String? { get }