CFNetwork错误代码引用
kCFURLErrorUnknown = -998, 未知错误
kCFURLErrorCancelled = -999, 错误取消
kCFURLErrorBadURL = -1000, 错误的URL
kCFURLErrorTimedOut = -1001, 请求超时
kCFURLErrorUnsupportedURL = -1002, 不支持的URL
kCFURLErrorCannotFindHost = -1003, 无法找到主机
kCFURLErrorCannotConnectToHost = -1004, 无法连接到主机
kCFURLErrorNetworkConnectionLost = -1005, 网络连接丢失
kCFURLErrorDNSLookupFailed = -1006, DNS查找失败
kCFURLErrorHTTPTooManyRedirects = -1007, HTTP重定向太多
kCFURLErrorResourceUnavailable = -1008, 错误的资源不可用
kCFURLErrorNotConnectedToInternet = -1009, 未连接互联网
kCFURLErrorRedirectToNonExistentLocation = -1010, 重定向到不存在的位置
kCFURLErrorBadServerResponse = -1011, 坏的服务器响应
kCFURLErrorUserCancelledAuthentication = -1012, 用户取消了身份验证
kCFURLErrorUserAuthenticationRequired = -1013, 用户身份验证要求
kCFURLErrorZeroByteResource = -1014, 错误零字节资源
kCFURLErrorCannotDecodeRawData = -1015, 无法解码原始数据
kCFURLErrorCannotDecodeContentData = -1016, 无法解码内容数据
kCFURLErrorCannotParseResponse = -1017, 不能解析响应
kCFURLErrorInternationalRoamingOff = -1018, 国际漫游了
kCFURLErrorCallIsActive = -1019, 愈伤组织活动
kCFURLErrorDataNotAllowed = -1020, 数据不允许
kCFURLErrorRequestBodyStreamExhausted = -1021, 请求体流耗尽
kCFURLErrorFileDoesNotExist = -1100, 文件不存在
kCFURLErrorFileIsDirectory = -1101, FileIs目录
kCFURLErrorNoPermissionsToReadFile = -1102, 没有读取文件的权限
kCFURLErrorDataLengthExceedsMaximum = -1103, 数据长度超过最大值