MoltinError

public enum MoltinError : Error

MoltinError encapsultes various errors that the SDK can return, as well as returning additional information if there are errors such as decoding errors

  • Thrown if a request could not authenticate

    Declaration

    Swift

    case couldNotAuthenticate
  • Thrown if the response returned an unacceptable error

    Declaration

    Swift

    case responseError(underlyingError: Error?)
  • Thrown if the data could not be added to the request

    Declaration

    Swift

    case couldNotSetData
  • Thrown if the response data can not be parsed correctly. Encapsulates a DecodingError for more infromation.

    Declaration

    Swift

    case couldNotParseData(underlyingError: DecodingError?)
  • Thrown if the response does not have any data

    Declaration

    Swift

    case couldNotFindData
  • Thrown if the response cannot parse a Date

    Declaration

    Swift

    case couldNotParseDate
  • Thrown if the request is not formed correctly

    Declaration

    Swift

    case unacceptableRequest
  • Thrown if no data was returned from the API

    Declaration

    Swift

    case noData
  • Declaration

    Swift

    public var errorDescription: String? { get }