File tree Expand file tree Collapse file tree 5 files changed +19
-10
lines changed
BuckoNetworking.xcodeproj Expand file tree Collapse file tree 5 files changed +19
-10
lines changed Original file line number Diff line number Diff line change 391391 buildSettings = {
392392 CLANG_ENABLE_MODULES = YES;
393393 CODE_SIGN_IDENTITY = "";
394+ CURRENT_PROJECT_VERSION = 1.1.0;
394395 DEFINES_MODULE = YES;
395396 DEVELOPMENT_TEAM = "";
396397 DYLIB_COMPATIBILITY_VERSION = 1;
417418 buildSettings = {
418419 CLANG_ENABLE_MODULES = YES;
419420 CODE_SIGN_IDENTITY = "";
421+ CURRENT_PROJECT_VERSION = 1.1.0;
420422 DEFINES_MODULE = YES;
421423 DEVELOPMENT_TEAM = "";
422424 DYLIB_COMPATIBILITY_VERSION = 1;
Original file line number Diff line number Diff line change @@ -15,12 +15,19 @@ public protocol BuckoErrorHandler: class {
1515}
1616
1717public typealias BuckoResponseClosure = ( ( DataResponse < Any > ) -> Void )
18+ @available ( * , deprecated, message: " Use HTTPMethod instead " )
1819public typealias HttpMethod = HTTPMethod
20+ @available ( * , deprecated, message: " Use HTTPHeaders instead " )
1921public typealias HttpHeaders = HTTPHeaders
22+ @available ( * , deprecated, message: " Use ParameterEncoding instead " )
2023public typealias Encoding = ParameterEncoding
24+ @available ( * , deprecated, message: " Use URLEncoding instead " )
2125public typealias UrlEncoding = URLEncoding
26+ @available ( * , deprecated, message: " Use JSONEncoding instead " )
2227public typealias JsonEncoding = JSONEncoding
28+ @available ( * , deprecated, message: " Use Parameters instead " )
2329public typealias Body = Parameters
30+ @available ( * , deprecated, message: " Use JSON instead " )
2431public typealias Json = JSON
2532
2633public struct Bucko {
Original file line number Diff line number Diff line change 1515 <key >CFBundlePackageType </key >
1616 <string >FMWK </string >
1717 <key >CFBundleShortVersionString </key >
18- <string >1.0 </string >
18+ <string >1.1. 0 </string >
1919 <key >CFBundleVersion </key >
2020 <string >$(CURRENT_PROJECT_VERSION) </string >
2121 <key >NSPrincipalClass </key >
Original file line number Diff line number Diff line change @@ -19,7 +19,7 @@ public protocol Endpoint {
1919 This will automatically be set by the baseURL and the path.
2020 */
2121 var fullURL : String { get }
22- var method : HttpMethod { get }
22+ var method : HTTPMethod { get }
2323
2424 /**
2525 By default, encoding will be set to URLEncoding for GET requests
@@ -31,31 +31,31 @@ public protocol Endpoint {
3131 PropertyListEncoding.default
3232 You can also create your own.
3333 */
34- var encoding : Encoding { get }
34+ var encoding : ParameterEncoding { get }
3535
3636 /**
3737 By default this will be set to empty - Parameters()
3838 */
39- var body : Body { get }
39+ var body : Parameters { get }
4040
4141 /**
4242 Authorization is usually set in the headers. You can set this to `[:]` if you don't have any
4343 headers to set. You can also create an extention on Endpoint to also have
4444 this default to a value.
4545 */
46- var headers : HttpHeaders { get }
46+ var headers : HTTPHeaders { get }
4747}
4848
4949public extension Endpoint {
50- var encoding : Encoding {
51- return method == . get ? UrlEncoding . default : JsonEncoding . default
50+ var encoding : ParameterEncoding {
51+ return method == . get ? URLEncoding . default : JSONEncoding . default
5252 }
5353
5454 var fullURL : String {
5555 return baseURL + path
5656 }
5757
58- var body : Body {
59- return Body ( )
58+ var body : Parameters {
59+ return Parameters ( )
6060 }
6161}
Original file line number Diff line number Diff line change 88
99public protocol JSONDecodable {
1010 associatedtype Model
11- static func map( from json: Json ) throws -> Model
11+ static func map( from json: JSON ) throws -> Model
1212}
You can’t perform that action at this time.
0 commit comments