Created
October 25, 2015 10:10
-
-
Save gmertk/8c698c1c418350ca1dc7 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
enum APIError : ErrorType { | |
// Can't connect to the server (maybe offline?) | |
case ConnectionError(error: NSError) | |
// The server responded with a non 200 status code | |
case ServerError(statusCode: Int, error: NSError) | |
// We got no data (0 bytes) back from the server | |
case NoDataError | |
// The server response can't be converted from JSON to a Dictionary | |
case JSONSerializationError(error: ErrorType) | |
// The Argo decoding Failed | |
case JSONMappingError(converstionError: DecodeError) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment