Result

public enum Result<T>

Boxes up results into success or failure cases This enum will either return success, with the corresponding value with the correct type, or return failure, with the corresponding error

  • Holds the success result

    Declaration

    Swift

    case success(result: T)
  • Holds the failure error

    Declaration

    Swift

    case failure(error: Error)