File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change 1
1
import Foundation
2
2
3
3
/// Used to store all response data returned from a completed request.
4
- public class Response : CustomDebugStringConvertible {
4
+ public struct Response : CustomDebugStringConvertible {
5
5
public let response : NSURLResponse ?
6
6
7
7
public let statusCode : Int
8
8
public let data : NSData
9
9
10
- public lazy var responseClass : ResponseClass = {
11
- return ResponseClass ( statusCode: self . statusCode)
10
+ public lazy var responseClass : ResponseStatus = {
11
+ return ResponseStatus ( statusCode: self . statusCode)
12
12
} ( )
13
13
14
14
public init ( statusCode: Int , data: NSData , response: NSURLResponse ? = nil ) {
@@ -36,7 +36,7 @@ public class Response: CustomDebugStringConvertible {
36
36
- serverError: status code in 500 to 599
37
37
- undefined: other status code
38
38
*/
39
- public enum ResponseClass {
39
+ public enum ResponseStatus {
40
40
case informational
41
41
case success
42
42
case redirection
You can’t perform that action at this time.
0 commit comments