├── .gitignore ├── .gitmodules ├── .swift-version ├── .travis.yml ├── Alamofire-SwiftyJSON.podspec ├── Alamofire-SwiftyJSON.xcodeproj ├── project.pbxproj ├── project.xcworkspace │ ├── contents.xcworkspacedata │ └── xcshareddata │ │ └── Alamofire-SwiftyJSON.xcscmblueprint └── xcshareddata │ └── xcschemes │ └── AlamofireSwiftyJSON.xcscheme ├── LICENSE ├── README.md ├── Source ├── Alamofire-SwiftyJSON.h ├── Alamofire-SwiftyJSON.swift └── Info.plist └── Tests ├── Alamofire_SwiftyJSONTests.swift └── Info.plist /.gitignore: -------------------------------------------------------------------------------- 1 | # Xcode 2 | # 3 | build/ 4 | *.pbxuser 5 | !default.pbxuser 6 | *.mode1v3 7 | !default.mode1v3 8 | *.mode2v3 9 | !default.mode2v3 10 | *.perspectivev3 11 | !default.perspectivev3 12 | xcuserdata 13 | *.xccheckout 14 | *.moved-aside 15 | DerivedData 16 | *.hmap 17 | *.ipa 18 | *.xcuserstate 19 | 20 | # CocoaPods 21 | # 22 | # We recommend against adding the Pods directory to your .gitignore. However 23 | # you should judge for yourself, the pros and cons are mentioned at: 24 | # http://guides.cocoapods.org/using/using-cocoapods.html#should-i-ignore-the-pods-directory-in-source-control 25 | # 26 | # Pods/ 27 | -------------------------------------------------------------------------------- /.gitmodules: -------------------------------------------------------------------------------- 1 | [submodule "SwiftyJSON"] 2 | path = SwiftyJSON 3 | url = https://github.com/SwiftyJSON/SwiftyJSON.git 4 | [submodule "Alamofire"] 5 | path = Alamofire 6 | url = https://github.com/Alamofire/Alamofire.git 7 | -------------------------------------------------------------------------------- /.swift-version: -------------------------------------------------------------------------------- 1 | 3.0 2 | -------------------------------------------------------------------------------- /.travis.yml: -------------------------------------------------------------------------------- 1 | language: objective-c 2 | osx_image: xcode9 3 | xcode_sdk: iphonesimulator10.0 4 | env: 5 | - PLATFORM="ios" SCHEME="AlamofireSwiftyJSON" DESTINATION="platform=iOS Simulator,name=iPhone SE,OS=10.0" 6 | script: 7 | - set -o pipefail && xcodebuild -project Alamofire-SwiftyJSON.xcodeproj -scheme $SCHEME -destination "$DESTINATION" build-for-testing test | xcpretty 8 | -------------------------------------------------------------------------------- /Alamofire-SwiftyJSON.podspec: -------------------------------------------------------------------------------- 1 | Pod::Spec.new do |s| 2 | s.name = "Alamofire-SwiftyJSON" 3 | s.version = "3.0.0" 4 | s.summary = "Alamofire extension for serialize NSData to SwiftyJSON " 5 | s.homepage = "https://github.com/SwiftyJSON/Alamofire-SwiftyJSON" 6 | s.license = { :type => "MIT" } 7 | s.authors = { "tangplin" => "tangplin@gmail.com" } 8 | 9 | s.requires_arc = true 10 | s.osx.deployment_target = "10.11" 11 | s.ios.deployment_target = "9.0" 12 | s.source = { :git => "https://github.com/SwiftyJSON/Alamofire-SwiftyJSON.git", :tag => s.version } 13 | s.source_files = "Source/*.swift" 14 | s.dependency 'Alamofire', '~> 4.5' 15 | s.dependency 'SwiftyJSON', '~> 4.0.0' 16 | end 17 | -------------------------------------------------------------------------------- /Alamofire-SwiftyJSON.xcodeproj/project.pbxproj: -------------------------------------------------------------------------------- 1 | // !$*UTF8*$! 2 | { 3 | archiveVersion = 1; 4 | classes = { 5 | }; 6 | objectVersion = 46; 7 | objects = { 8 | 9 | /* Begin PBXBuildFile section */ 10 | A8A2DBBA1A23292000AF9EFC /* Alamofire.framework in Copy Frameworks */ = {isa = PBXBuildFile; fileRef = A8AFB75A19D14A5C0070765E /* Alamofire.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; 11 | A8A2DBBB1A23292000AF9EFC /* SwiftyJSON.framework in Copy Frameworks */ = {isa = PBXBuildFile; fileRef = A8AFB76519D14A670070765E /* SwiftyJSON.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; 12 | A8A2DBC31A2329E700AF9EFC /* Alamofire.framework in Copy Frameworks */ = {isa = PBXBuildFile; fileRef = A8AFB75A19D14A5C0070765E /* Alamofire.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; 13 | A8A2DBC41A2329E700AF9EFC /* SwiftyJSON.framework in Copy Frameworks */ = {isa = PBXBuildFile; fileRef = A8AFB76519D14A670070765E /* SwiftyJSON.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; 14 | A8A2DBC51A2329E700AF9EFC /* AlamofireSwiftyJSON.framework in Copy Frameworks */ = {isa = PBXBuildFile; fileRef = A8AFB70F19D1401D0070765E /* AlamofireSwiftyJSON.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; 15 | A8AFB71519D1401D0070765E /* Alamofire-SwiftyJSON.h in Headers */ = {isa = PBXBuildFile; fileRef = A8AFB71419D1401D0070765E /* Alamofire-SwiftyJSON.h */; settings = {ATTRIBUTES = (Public, ); }; }; 16 | A8AFB71F19D1401D0070765E /* Alamofire_SwiftyJSONTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = A8AFB71E19D1401D0070765E /* Alamofire_SwiftyJSONTests.swift */; }; 17 | A8AFB72919D140BD0070765E /* Alamofire-SwiftyJSON.swift in Sources */ = {isa = PBXBuildFile; fileRef = A8AFB72819D140BD0070765E /* Alamofire-SwiftyJSON.swift */; }; 18 | /* End PBXBuildFile section */ 19 | 20 | /* Begin PBXContainerItemProxy section */ 21 | 4BC5E9F91BB7E15600A393DD /* PBXContainerItemProxy */ = { 22 | isa = PBXContainerItemProxy; 23 | containerPortal = A8AFB75419D14A5C0070765E /* Alamofire.xcodeproj */; 24 | proxyType = 2; 25 | remoteGlobalIDString = 4DD67C0B1A5C55C900ED2280; 26 | remoteInfo = "Alamofire OSX"; 27 | }; 28 | 4BC5E9FB1BB7E15600A393DD /* PBXContainerItemProxy */ = { 29 | isa = PBXContainerItemProxy; 30 | containerPortal = A8AFB75419D14A5C0070765E /* Alamofire.xcodeproj */; 31 | proxyType = 2; 32 | remoteGlobalIDString = E4202FE01B667AA100C997FB; 33 | remoteInfo = "Alamofire watchOS"; 34 | }; 35 | 4BC5E9FD1BB7E15600A393DD /* PBXContainerItemProxy */ = { 36 | isa = PBXContainerItemProxy; 37 | containerPortal = A8AFB75419D14A5C0070765E /* Alamofire.xcodeproj */; 38 | proxyType = 2; 39 | remoteGlobalIDString = F829C6B21A7A94F100A2CD59; 40 | remoteInfo = "Alamofire OSX Tests"; 41 | }; 42 | 4BC5EA031BB7E15600A393DD /* PBXContainerItemProxy */ = { 43 | isa = PBXContainerItemProxy; 44 | containerPortal = A8AFB75D19D14A670070765E /* SwiftyJSON.xcodeproj */; 45 | proxyType = 2; 46 | remoteGlobalIDString = 9C7DFC5B1A9102BD005AA3F7; 47 | remoteInfo = "SwiftyJSON OSX"; 48 | }; 49 | 4BC5EA051BB7E15600A393DD /* PBXContainerItemProxy */ = { 50 | isa = PBXContainerItemProxy; 51 | containerPortal = A8AFB75D19D14A670070765E /* SwiftyJSON.xcodeproj */; 52 | proxyType = 2; 53 | remoteGlobalIDString = 9C7DFC651A9102BD005AA3F7; 54 | remoteInfo = "SwiftyJSON OSX Tests"; 55 | }; 56 | 4BC5EA071BB7E15600A393DD /* PBXContainerItemProxy */ = { 57 | isa = PBXContainerItemProxy; 58 | containerPortal = A8AFB75D19D14A670070765E /* SwiftyJSON.xcodeproj */; 59 | proxyType = 2; 60 | remoteGlobalIDString = E4D7CCE81B9465A700EE7221; 61 | remoteInfo = "SwiftyJSON watchOS"; 62 | }; 63 | A81D16431E59E90500C62C5F /* PBXContainerItemProxy */ = { 64 | isa = PBXContainerItemProxy; 65 | containerPortal = A8AFB75419D14A5C0070765E /* Alamofire.xcodeproj */; 66 | proxyType = 2; 67 | remoteGlobalIDString = 4CF626EF1BA7CB3E0011A099; 68 | remoteInfo = "Alamofire tvOS"; 69 | }; 70 | A81D16451E59E90500C62C5F /* PBXContainerItemProxy */ = { 71 | isa = PBXContainerItemProxy; 72 | containerPortal = A8AFB75419D14A5C0070765E /* Alamofire.xcodeproj */; 73 | proxyType = 2; 74 | remoteGlobalIDString = 4CF626F81BA7CB3E0011A099; 75 | remoteInfo = "Alamofire tvOS Tests"; 76 | }; 77 | A81D164D1E59E90500C62C5F /* PBXContainerItemProxy */ = { 78 | isa = PBXContainerItemProxy; 79 | containerPortal = A8AFB75D19D14A670070765E /* SwiftyJSON.xcodeproj */; 80 | proxyType = 2; 81 | remoteGlobalIDString = 7236B4F61BAC14150020529B; 82 | remoteInfo = "SwiftyJSON tvOS"; 83 | }; 84 | A81D164F1E59E90500C62C5F /* PBXContainerItemProxy */ = { 85 | isa = PBXContainerItemProxy; 86 | containerPortal = A8AFB75D19D14A670070765E /* SwiftyJSON.xcodeproj */; 87 | proxyType = 2; 88 | remoteGlobalIDString = A8580F741BCF5C5B00DA927B; 89 | remoteInfo = "SwiftyJSON tvOS Tests"; 90 | }; 91 | A8A2DBB61A23290100AF9EFC /* PBXContainerItemProxy */ = { 92 | isa = PBXContainerItemProxy; 93 | containerPortal = A8AFB75419D14A5C0070765E /* Alamofire.xcodeproj */; 94 | proxyType = 1; 95 | remoteGlobalIDString = F8111E3219A95C8B0040E7D1; 96 | remoteInfo = Alamofire; 97 | }; 98 | A8A2DBB81A23290100AF9EFC /* PBXContainerItemProxy */ = { 99 | isa = PBXContainerItemProxy; 100 | containerPortal = A8AFB75D19D14A670070765E /* SwiftyJSON.xcodeproj */; 101 | proxyType = 1; 102 | remoteGlobalIDString = 2E4FEFDA19575BE100351305; 103 | remoteInfo = SwiftyJSON; 104 | }; 105 | A8A2DBBC1A2329BD00AF9EFC /* PBXContainerItemProxy */ = { 106 | isa = PBXContainerItemProxy; 107 | containerPortal = A8AFB70619D1401D0070765E /* Project object */; 108 | proxyType = 1; 109 | remoteGlobalIDString = A8AFB70E19D1401D0070765E; 110 | remoteInfo = AlamofireSwiftyJSON; 111 | }; 112 | A8A2DBBE1A2329BD00AF9EFC /* PBXContainerItemProxy */ = { 113 | isa = PBXContainerItemProxy; 114 | containerPortal = A8AFB75419D14A5C0070765E /* Alamofire.xcodeproj */; 115 | proxyType = 1; 116 | remoteGlobalIDString = F8111E3219A95C8B0040E7D1; 117 | remoteInfo = Alamofire; 118 | }; 119 | A8A2DBC01A2329BD00AF9EFC /* PBXContainerItemProxy */ = { 120 | isa = PBXContainerItemProxy; 121 | containerPortal = A8AFB75D19D14A670070765E /* SwiftyJSON.xcodeproj */; 122 | proxyType = 1; 123 | remoteGlobalIDString = 2E4FEFDA19575BE100351305; 124 | remoteInfo = SwiftyJSON; 125 | }; 126 | A8AFB75919D14A5C0070765E /* PBXContainerItemProxy */ = { 127 | isa = PBXContainerItemProxy; 128 | containerPortal = A8AFB75419D14A5C0070765E /* Alamofire.xcodeproj */; 129 | proxyType = 2; 130 | remoteGlobalIDString = F8111E3319A95C8B0040E7D1; 131 | remoteInfo = Alamofire; 132 | }; 133 | A8AFB75B19D14A5C0070765E /* PBXContainerItemProxy */ = { 134 | isa = PBXContainerItemProxy; 135 | containerPortal = A8AFB75419D14A5C0070765E /* Alamofire.xcodeproj */; 136 | proxyType = 2; 137 | remoteGlobalIDString = F8111E3E19A95C8B0040E7D1; 138 | remoteInfo = AlamofireTests; 139 | }; 140 | A8AFB76419D14A670070765E /* PBXContainerItemProxy */ = { 141 | isa = PBXContainerItemProxy; 142 | containerPortal = A8AFB75D19D14A670070765E /* SwiftyJSON.xcodeproj */; 143 | proxyType = 2; 144 | remoteGlobalIDString = 2E4FEFDB19575BE100351305; 145 | remoteInfo = SwiftyJSON; 146 | }; 147 | A8AFB76619D14A670070765E /* PBXContainerItemProxy */ = { 148 | isa = PBXContainerItemProxy; 149 | containerPortal = A8AFB75D19D14A670070765E /* SwiftyJSON.xcodeproj */; 150 | proxyType = 2; 151 | remoteGlobalIDString = 2E4FEFE619575BE100351305; 152 | remoteInfo = SwiftyJSONTests; 153 | }; 154 | /* End PBXContainerItemProxy section */ 155 | 156 | /* Begin PBXCopyFilesBuildPhase section */ 157 | A82ED83919ED37D300A502B1 /* Copy Frameworks */ = { 158 | isa = PBXCopyFilesBuildPhase; 159 | buildActionMask = 8; 160 | dstPath = ""; 161 | dstSubfolderSpec = 10; 162 | files = ( 163 | A8A2DBBA1A23292000AF9EFC /* Alamofire.framework in Copy Frameworks */, 164 | A8A2DBBB1A23292000AF9EFC /* SwiftyJSON.framework in Copy Frameworks */, 165 | ); 166 | name = "Copy Frameworks"; 167 | runOnlyForDeploymentPostprocessing = 1; 168 | }; 169 | A8A2DBC21A2329CE00AF9EFC /* Copy Frameworks */ = { 170 | isa = PBXCopyFilesBuildPhase; 171 | buildActionMask = 12; 172 | dstPath = ""; 173 | dstSubfolderSpec = 10; 174 | files = ( 175 | A8A2DBC31A2329E700AF9EFC /* Alamofire.framework in Copy Frameworks */, 176 | A8A2DBC41A2329E700AF9EFC /* SwiftyJSON.framework in Copy Frameworks */, 177 | A8A2DBC51A2329E700AF9EFC /* AlamofireSwiftyJSON.framework in Copy Frameworks */, 178 | ); 179 | name = "Copy Frameworks"; 180 | runOnlyForDeploymentPostprocessing = 0; 181 | }; 182 | /* End PBXCopyFilesBuildPhase section */ 183 | 184 | /* Begin PBXFileReference section */ 185 | A8AFB70F19D1401D0070765E /* AlamofireSwiftyJSON.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = AlamofireSwiftyJSON.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 186 | A8AFB71319D1401D0070765E /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 187 | A8AFB71419D1401D0070765E /* Alamofire-SwiftyJSON.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "Alamofire-SwiftyJSON.h"; sourceTree = ""; }; 188 | A8AFB71A19D1401D0070765E /* AlamofireSwiftyJSONTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = AlamofireSwiftyJSONTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; 189 | A8AFB71D19D1401D0070765E /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 190 | A8AFB71E19D1401D0070765E /* Alamofire_SwiftyJSONTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Alamofire_SwiftyJSONTests.swift; sourceTree = ""; }; 191 | A8AFB72819D140BD0070765E /* Alamofire-SwiftyJSON.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = "Alamofire-SwiftyJSON.swift"; sourceTree = ""; }; 192 | A8AFB75419D14A5C0070765E /* Alamofire.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = Alamofire.xcodeproj; path = Alamofire/Alamofire.xcodeproj; sourceTree = ""; }; 193 | A8AFB75D19D14A670070765E /* SwiftyJSON.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = SwiftyJSON.xcodeproj; path = SwiftyJSON/SwiftyJSON.xcodeproj; sourceTree = ""; }; 194 | /* End PBXFileReference section */ 195 | 196 | /* Begin PBXFrameworksBuildPhase section */ 197 | A8AFB70B19D1401D0070765E /* Frameworks */ = { 198 | isa = PBXFrameworksBuildPhase; 199 | buildActionMask = 2147483647; 200 | files = ( 201 | ); 202 | runOnlyForDeploymentPostprocessing = 0; 203 | }; 204 | A8AFB71719D1401D0070765E /* Frameworks */ = { 205 | isa = PBXFrameworksBuildPhase; 206 | buildActionMask = 2147483647; 207 | files = ( 208 | ); 209 | runOnlyForDeploymentPostprocessing = 0; 210 | }; 211 | /* End PBXFrameworksBuildPhase section */ 212 | 213 | /* Begin PBXGroup section */ 214 | A8AFB70519D1401D0070765E = { 215 | isa = PBXGroup; 216 | children = ( 217 | A8AFB75419D14A5C0070765E /* Alamofire.xcodeproj */, 218 | A8AFB75D19D14A670070765E /* SwiftyJSON.xcodeproj */, 219 | A8AFB71119D1401D0070765E /* Source */, 220 | A8AFB71B19D1401D0070765E /* Tests */, 221 | A8AFB71019D1401D0070765E /* Products */, 222 | ); 223 | sourceTree = ""; 224 | }; 225 | A8AFB71019D1401D0070765E /* Products */ = { 226 | isa = PBXGroup; 227 | children = ( 228 | A8AFB70F19D1401D0070765E /* AlamofireSwiftyJSON.framework */, 229 | A8AFB71A19D1401D0070765E /* AlamofireSwiftyJSONTests.xctest */, 230 | ); 231 | name = Products; 232 | sourceTree = ""; 233 | }; 234 | A8AFB71119D1401D0070765E /* Source */ = { 235 | isa = PBXGroup; 236 | children = ( 237 | A8AFB71419D1401D0070765E /* Alamofire-SwiftyJSON.h */, 238 | A8AFB72819D140BD0070765E /* Alamofire-SwiftyJSON.swift */, 239 | A8AFB71219D1401D0070765E /* Supporting Files */, 240 | ); 241 | path = Source; 242 | sourceTree = ""; 243 | }; 244 | A8AFB71219D1401D0070765E /* Supporting Files */ = { 245 | isa = PBXGroup; 246 | children = ( 247 | A8AFB71319D1401D0070765E /* Info.plist */, 248 | ); 249 | name = "Supporting Files"; 250 | sourceTree = ""; 251 | }; 252 | A8AFB71B19D1401D0070765E /* Tests */ = { 253 | isa = PBXGroup; 254 | children = ( 255 | A8AFB71E19D1401D0070765E /* Alamofire_SwiftyJSONTests.swift */, 256 | A8AFB71C19D1401D0070765E /* Supporting Files */, 257 | ); 258 | path = Tests; 259 | sourceTree = ""; 260 | }; 261 | A8AFB71C19D1401D0070765E /* Supporting Files */ = { 262 | isa = PBXGroup; 263 | children = ( 264 | A8AFB71D19D1401D0070765E /* Info.plist */, 265 | ); 266 | name = "Supporting Files"; 267 | sourceTree = ""; 268 | }; 269 | A8AFB75519D14A5C0070765E /* Products */ = { 270 | isa = PBXGroup; 271 | children = ( 272 | A8AFB75A19D14A5C0070765E /* Alamofire.framework */, 273 | A8AFB75C19D14A5C0070765E /* Alamofire iOS Tests.xctest */, 274 | 4BC5E9FA1BB7E15600A393DD /* Alamofire.framework */, 275 | 4BC5E9FE1BB7E15600A393DD /* Alamofire macOS Tests.xctest */, 276 | A81D16441E59E90500C62C5F /* Alamofire.framework */, 277 | A81D16461E59E90500C62C5F /* Alamofire tvOS Tests.xctest */, 278 | 4BC5E9FC1BB7E15600A393DD /* Alamofire.framework */, 279 | ); 280 | name = Products; 281 | sourceTree = ""; 282 | }; 283 | A8AFB75E19D14A670070765E /* Products */ = { 284 | isa = PBXGroup; 285 | children = ( 286 | A8AFB76519D14A670070765E /* SwiftyJSON.framework */, 287 | A8AFB76719D14A670070765E /* SwiftyJSON iOS Tests.xctest */, 288 | 4BC5EA041BB7E15600A393DD /* SwiftyJSON.framework */, 289 | 4BC5EA061BB7E15600A393DD /* SwiftyJSON OSX Tests.xctest */, 290 | 4BC5EA081BB7E15600A393DD /* SwiftyJSON.framework */, 291 | A81D164E1E59E90500C62C5F /* SwiftyJSON.framework */, 292 | A81D16501E59E90500C62C5F /* SwiftyJSON tvOS Tests.xctest */, 293 | ); 294 | name = Products; 295 | sourceTree = ""; 296 | }; 297 | /* End PBXGroup section */ 298 | 299 | /* Begin PBXHeadersBuildPhase section */ 300 | A8AFB70C19D1401D0070765E /* Headers */ = { 301 | isa = PBXHeadersBuildPhase; 302 | buildActionMask = 2147483647; 303 | files = ( 304 | A8AFB71519D1401D0070765E /* Alamofire-SwiftyJSON.h in Headers */, 305 | ); 306 | runOnlyForDeploymentPostprocessing = 0; 307 | }; 308 | /* End PBXHeadersBuildPhase section */ 309 | 310 | /* Begin PBXNativeTarget section */ 311 | A8AFB70E19D1401D0070765E /* AlamofireSwiftyJSON */ = { 312 | isa = PBXNativeTarget; 313 | buildConfigurationList = A8AFB72219D1401D0070765E /* Build configuration list for PBXNativeTarget "AlamofireSwiftyJSON" */; 314 | buildPhases = ( 315 | A8AFB70A19D1401D0070765E /* Sources */, 316 | A8AFB70B19D1401D0070765E /* Frameworks */, 317 | A8AFB70C19D1401D0070765E /* Headers */, 318 | A8AFB70D19D1401D0070765E /* Resources */, 319 | A82ED83919ED37D300A502B1 /* Copy Frameworks */, 320 | ); 321 | buildRules = ( 322 | ); 323 | dependencies = ( 324 | A8A2DBB71A23290100AF9EFC /* PBXTargetDependency */, 325 | A8A2DBB91A23290100AF9EFC /* PBXTargetDependency */, 326 | ); 327 | name = AlamofireSwiftyJSON; 328 | productName = "Alamofire-SwiftyJSON"; 329 | productReference = A8AFB70F19D1401D0070765E /* AlamofireSwiftyJSON.framework */; 330 | productType = "com.apple.product-type.framework"; 331 | }; 332 | A8AFB71919D1401D0070765E /* AlamofireSwiftyJSONTests */ = { 333 | isa = PBXNativeTarget; 334 | buildConfigurationList = A8AFB72519D1401D0070765E /* Build configuration list for PBXNativeTarget "AlamofireSwiftyJSONTests" */; 335 | buildPhases = ( 336 | A8AFB71619D1401D0070765E /* Sources */, 337 | A8AFB71719D1401D0070765E /* Frameworks */, 338 | A8AFB71819D1401D0070765E /* Resources */, 339 | A8A2DBC21A2329CE00AF9EFC /* Copy Frameworks */, 340 | ); 341 | buildRules = ( 342 | ); 343 | dependencies = ( 344 | A8A2DBBD1A2329BD00AF9EFC /* PBXTargetDependency */, 345 | A8A2DBBF1A2329BD00AF9EFC /* PBXTargetDependency */, 346 | A8A2DBC11A2329BD00AF9EFC /* PBXTargetDependency */, 347 | ); 348 | name = AlamofireSwiftyJSONTests; 349 | productName = "Alamofire-SwiftyJSONTests"; 350 | productReference = A8AFB71A19D1401D0070765E /* AlamofireSwiftyJSONTests.xctest */; 351 | productType = "com.apple.product-type.bundle.unit-test"; 352 | }; 353 | /* End PBXNativeTarget section */ 354 | 355 | /* Begin PBXProject section */ 356 | A8AFB70619D1401D0070765E /* Project object */ = { 357 | isa = PBXProject; 358 | attributes = { 359 | LastSwiftUpdateCheck = 0700; 360 | LastUpgradeCheck = 0900; 361 | ORGANIZATIONNAME = SwiftJSON; 362 | TargetAttributes = { 363 | A8AFB70E19D1401D0070765E = { 364 | CreatedOnToolsVersion = 6.0.1; 365 | LastSwiftMigration = 0820; 366 | }; 367 | A8AFB71919D1401D0070765E = { 368 | CreatedOnToolsVersion = 6.0.1; 369 | LastSwiftMigration = 0820; 370 | }; 371 | }; 372 | }; 373 | buildConfigurationList = A8AFB70919D1401D0070765E /* Build configuration list for PBXProject "Alamofire-SwiftyJSON" */; 374 | compatibilityVersion = "Xcode 3.2"; 375 | developmentRegion = English; 376 | hasScannedForEncodings = 0; 377 | knownRegions = ( 378 | en, 379 | ); 380 | mainGroup = A8AFB70519D1401D0070765E; 381 | productRefGroup = A8AFB71019D1401D0070765E /* Products */; 382 | projectDirPath = ""; 383 | projectReferences = ( 384 | { 385 | ProductGroup = A8AFB75519D14A5C0070765E /* Products */; 386 | ProjectRef = A8AFB75419D14A5C0070765E /* Alamofire.xcodeproj */; 387 | }, 388 | { 389 | ProductGroup = A8AFB75E19D14A670070765E /* Products */; 390 | ProjectRef = A8AFB75D19D14A670070765E /* SwiftyJSON.xcodeproj */; 391 | }, 392 | ); 393 | projectRoot = ""; 394 | targets = ( 395 | A8AFB70E19D1401D0070765E /* AlamofireSwiftyJSON */, 396 | A8AFB71919D1401D0070765E /* AlamofireSwiftyJSONTests */, 397 | ); 398 | }; 399 | /* End PBXProject section */ 400 | 401 | /* Begin PBXReferenceProxy section */ 402 | 4BC5E9FA1BB7E15600A393DD /* Alamofire.framework */ = { 403 | isa = PBXReferenceProxy; 404 | fileType = wrapper.framework; 405 | path = Alamofire.framework; 406 | remoteRef = 4BC5E9F91BB7E15600A393DD /* PBXContainerItemProxy */; 407 | sourceTree = BUILT_PRODUCTS_DIR; 408 | }; 409 | 4BC5E9FC1BB7E15600A393DD /* Alamofire.framework */ = { 410 | isa = PBXReferenceProxy; 411 | fileType = wrapper.framework; 412 | path = Alamofire.framework; 413 | remoteRef = 4BC5E9FB1BB7E15600A393DD /* PBXContainerItemProxy */; 414 | sourceTree = BUILT_PRODUCTS_DIR; 415 | }; 416 | 4BC5E9FE1BB7E15600A393DD /* Alamofire macOS Tests.xctest */ = { 417 | isa = PBXReferenceProxy; 418 | fileType = wrapper.cfbundle; 419 | path = "Alamofire macOS Tests.xctest"; 420 | remoteRef = 4BC5E9FD1BB7E15600A393DD /* PBXContainerItemProxy */; 421 | sourceTree = BUILT_PRODUCTS_DIR; 422 | }; 423 | 4BC5EA041BB7E15600A393DD /* SwiftyJSON.framework */ = { 424 | isa = PBXReferenceProxy; 425 | fileType = wrapper.framework; 426 | path = SwiftyJSON.framework; 427 | remoteRef = 4BC5EA031BB7E15600A393DD /* PBXContainerItemProxy */; 428 | sourceTree = BUILT_PRODUCTS_DIR; 429 | }; 430 | 4BC5EA061BB7E15600A393DD /* SwiftyJSON OSX Tests.xctest */ = { 431 | isa = PBXReferenceProxy; 432 | fileType = wrapper.cfbundle; 433 | path = "SwiftyJSON OSX Tests.xctest"; 434 | remoteRef = 4BC5EA051BB7E15600A393DD /* PBXContainerItemProxy */; 435 | sourceTree = BUILT_PRODUCTS_DIR; 436 | }; 437 | 4BC5EA081BB7E15600A393DD /* SwiftyJSON.framework */ = { 438 | isa = PBXReferenceProxy; 439 | fileType = wrapper.framework; 440 | path = SwiftyJSON.framework; 441 | remoteRef = 4BC5EA071BB7E15600A393DD /* PBXContainerItemProxy */; 442 | sourceTree = BUILT_PRODUCTS_DIR; 443 | }; 444 | A81D16441E59E90500C62C5F /* Alamofire.framework */ = { 445 | isa = PBXReferenceProxy; 446 | fileType = wrapper.framework; 447 | path = Alamofire.framework; 448 | remoteRef = A81D16431E59E90500C62C5F /* PBXContainerItemProxy */; 449 | sourceTree = BUILT_PRODUCTS_DIR; 450 | }; 451 | A81D16461E59E90500C62C5F /* Alamofire tvOS Tests.xctest */ = { 452 | isa = PBXReferenceProxy; 453 | fileType = wrapper.cfbundle; 454 | path = "Alamofire tvOS Tests.xctest"; 455 | remoteRef = A81D16451E59E90500C62C5F /* PBXContainerItemProxy */; 456 | sourceTree = BUILT_PRODUCTS_DIR; 457 | }; 458 | A81D164E1E59E90500C62C5F /* SwiftyJSON.framework */ = { 459 | isa = PBXReferenceProxy; 460 | fileType = wrapper.framework; 461 | path = SwiftyJSON.framework; 462 | remoteRef = A81D164D1E59E90500C62C5F /* PBXContainerItemProxy */; 463 | sourceTree = BUILT_PRODUCTS_DIR; 464 | }; 465 | A81D16501E59E90500C62C5F /* SwiftyJSON tvOS Tests.xctest */ = { 466 | isa = PBXReferenceProxy; 467 | fileType = wrapper.cfbundle; 468 | path = "SwiftyJSON tvOS Tests.xctest"; 469 | remoteRef = A81D164F1E59E90500C62C5F /* PBXContainerItemProxy */; 470 | sourceTree = BUILT_PRODUCTS_DIR; 471 | }; 472 | A8AFB75A19D14A5C0070765E /* Alamofire.framework */ = { 473 | isa = PBXReferenceProxy; 474 | fileType = wrapper.framework; 475 | path = Alamofire.framework; 476 | remoteRef = A8AFB75919D14A5C0070765E /* PBXContainerItemProxy */; 477 | sourceTree = BUILT_PRODUCTS_DIR; 478 | }; 479 | A8AFB75C19D14A5C0070765E /* Alamofire iOS Tests.xctest */ = { 480 | isa = PBXReferenceProxy; 481 | fileType = wrapper.cfbundle; 482 | path = "Alamofire iOS Tests.xctest"; 483 | remoteRef = A8AFB75B19D14A5C0070765E /* PBXContainerItemProxy */; 484 | sourceTree = BUILT_PRODUCTS_DIR; 485 | }; 486 | A8AFB76519D14A670070765E /* SwiftyJSON.framework */ = { 487 | isa = PBXReferenceProxy; 488 | fileType = wrapper.framework; 489 | path = SwiftyJSON.framework; 490 | remoteRef = A8AFB76419D14A670070765E /* PBXContainerItemProxy */; 491 | sourceTree = BUILT_PRODUCTS_DIR; 492 | }; 493 | A8AFB76719D14A670070765E /* SwiftyJSON iOS Tests.xctest */ = { 494 | isa = PBXReferenceProxy; 495 | fileType = wrapper.cfbundle; 496 | path = "SwiftyJSON iOS Tests.xctest"; 497 | remoteRef = A8AFB76619D14A670070765E /* PBXContainerItemProxy */; 498 | sourceTree = BUILT_PRODUCTS_DIR; 499 | }; 500 | /* End PBXReferenceProxy section */ 501 | 502 | /* Begin PBXResourcesBuildPhase section */ 503 | A8AFB70D19D1401D0070765E /* Resources */ = { 504 | isa = PBXResourcesBuildPhase; 505 | buildActionMask = 2147483647; 506 | files = ( 507 | ); 508 | runOnlyForDeploymentPostprocessing = 0; 509 | }; 510 | A8AFB71819D1401D0070765E /* Resources */ = { 511 | isa = PBXResourcesBuildPhase; 512 | buildActionMask = 2147483647; 513 | files = ( 514 | ); 515 | runOnlyForDeploymentPostprocessing = 0; 516 | }; 517 | /* End PBXResourcesBuildPhase section */ 518 | 519 | /* Begin PBXSourcesBuildPhase section */ 520 | A8AFB70A19D1401D0070765E /* Sources */ = { 521 | isa = PBXSourcesBuildPhase; 522 | buildActionMask = 2147483647; 523 | files = ( 524 | A8AFB72919D140BD0070765E /* Alamofire-SwiftyJSON.swift in Sources */, 525 | ); 526 | runOnlyForDeploymentPostprocessing = 0; 527 | }; 528 | A8AFB71619D1401D0070765E /* Sources */ = { 529 | isa = PBXSourcesBuildPhase; 530 | buildActionMask = 2147483647; 531 | files = ( 532 | A8AFB71F19D1401D0070765E /* Alamofire_SwiftyJSONTests.swift in Sources */, 533 | ); 534 | runOnlyForDeploymentPostprocessing = 0; 535 | }; 536 | /* End PBXSourcesBuildPhase section */ 537 | 538 | /* Begin PBXTargetDependency section */ 539 | A8A2DBB71A23290100AF9EFC /* PBXTargetDependency */ = { 540 | isa = PBXTargetDependency; 541 | name = Alamofire; 542 | targetProxy = A8A2DBB61A23290100AF9EFC /* PBXContainerItemProxy */; 543 | }; 544 | A8A2DBB91A23290100AF9EFC /* PBXTargetDependency */ = { 545 | isa = PBXTargetDependency; 546 | name = SwiftyJSON; 547 | targetProxy = A8A2DBB81A23290100AF9EFC /* PBXContainerItemProxy */; 548 | }; 549 | A8A2DBBD1A2329BD00AF9EFC /* PBXTargetDependency */ = { 550 | isa = PBXTargetDependency; 551 | target = A8AFB70E19D1401D0070765E /* AlamofireSwiftyJSON */; 552 | targetProxy = A8A2DBBC1A2329BD00AF9EFC /* PBXContainerItemProxy */; 553 | }; 554 | A8A2DBBF1A2329BD00AF9EFC /* PBXTargetDependency */ = { 555 | isa = PBXTargetDependency; 556 | name = Alamofire; 557 | targetProxy = A8A2DBBE1A2329BD00AF9EFC /* PBXContainerItemProxy */; 558 | }; 559 | A8A2DBC11A2329BD00AF9EFC /* PBXTargetDependency */ = { 560 | isa = PBXTargetDependency; 561 | name = SwiftyJSON; 562 | targetProxy = A8A2DBC01A2329BD00AF9EFC /* PBXContainerItemProxy */; 563 | }; 564 | /* End PBXTargetDependency section */ 565 | 566 | /* Begin XCBuildConfiguration section */ 567 | A8AFB72019D1401D0070765E /* Debug */ = { 568 | isa = XCBuildConfiguration; 569 | buildSettings = { 570 | ALWAYS_SEARCH_USER_PATHS = NO; 571 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 572 | CLANG_CXX_LIBRARY = "libc++"; 573 | CLANG_ENABLE_MODULES = YES; 574 | CLANG_ENABLE_OBJC_ARC = YES; 575 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 576 | CLANG_WARN_BOOL_CONVERSION = YES; 577 | CLANG_WARN_COMMA = YES; 578 | CLANG_WARN_CONSTANT_CONVERSION = YES; 579 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 580 | CLANG_WARN_EMPTY_BODY = YES; 581 | CLANG_WARN_ENUM_CONVERSION = YES; 582 | CLANG_WARN_INFINITE_RECURSION = YES; 583 | CLANG_WARN_INT_CONVERSION = YES; 584 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 585 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 586 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 587 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 588 | CLANG_WARN_STRICT_PROTOTYPES = YES; 589 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 590 | CLANG_WARN_UNREACHABLE_CODE = YES; 591 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 592 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 593 | COPY_PHASE_STRIP = NO; 594 | CURRENT_PROJECT_VERSION = 1; 595 | ENABLE_STRICT_OBJC_MSGSEND = YES; 596 | ENABLE_TESTABILITY = YES; 597 | GCC_C_LANGUAGE_STANDARD = gnu99; 598 | GCC_DYNAMIC_NO_PIC = NO; 599 | GCC_NO_COMMON_BLOCKS = YES; 600 | GCC_OPTIMIZATION_LEVEL = 0; 601 | GCC_PREPROCESSOR_DEFINITIONS = ( 602 | "DEBUG=1", 603 | "$(inherited)", 604 | ); 605 | GCC_SYMBOLS_PRIVATE_EXTERN = NO; 606 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 607 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 608 | GCC_WARN_UNDECLARED_SELECTOR = YES; 609 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 610 | GCC_WARN_UNUSED_FUNCTION = YES; 611 | GCC_WARN_UNUSED_VARIABLE = YES; 612 | IPHONEOS_DEPLOYMENT_TARGET = 8.0; 613 | MTL_ENABLE_DEBUG_INFO = YES; 614 | ONLY_ACTIVE_ARCH = YES; 615 | SDKROOT = iphoneos; 616 | SWIFT_OPTIMIZATION_LEVEL = "-Onone"; 617 | TARGETED_DEVICE_FAMILY = "1,2"; 618 | VERSIONING_SYSTEM = "apple-generic"; 619 | VERSION_INFO_PREFIX = ""; 620 | }; 621 | name = Debug; 622 | }; 623 | A8AFB72119D1401D0070765E /* Release */ = { 624 | isa = XCBuildConfiguration; 625 | buildSettings = { 626 | ALWAYS_SEARCH_USER_PATHS = NO; 627 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 628 | CLANG_CXX_LIBRARY = "libc++"; 629 | CLANG_ENABLE_MODULES = YES; 630 | CLANG_ENABLE_OBJC_ARC = YES; 631 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 632 | CLANG_WARN_BOOL_CONVERSION = YES; 633 | CLANG_WARN_COMMA = YES; 634 | CLANG_WARN_CONSTANT_CONVERSION = YES; 635 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 636 | CLANG_WARN_EMPTY_BODY = YES; 637 | CLANG_WARN_ENUM_CONVERSION = YES; 638 | CLANG_WARN_INFINITE_RECURSION = YES; 639 | CLANG_WARN_INT_CONVERSION = YES; 640 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 641 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 642 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 643 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 644 | CLANG_WARN_STRICT_PROTOTYPES = YES; 645 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 646 | CLANG_WARN_UNREACHABLE_CODE = YES; 647 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 648 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 649 | COPY_PHASE_STRIP = NO; 650 | CURRENT_PROJECT_VERSION = 1; 651 | ENABLE_NS_ASSERTIONS = NO; 652 | ENABLE_STRICT_OBJC_MSGSEND = YES; 653 | GCC_C_LANGUAGE_STANDARD = gnu99; 654 | GCC_NO_COMMON_BLOCKS = YES; 655 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 656 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 657 | GCC_WARN_UNDECLARED_SELECTOR = YES; 658 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 659 | GCC_WARN_UNUSED_FUNCTION = YES; 660 | GCC_WARN_UNUSED_VARIABLE = YES; 661 | IPHONEOS_DEPLOYMENT_TARGET = 8.0; 662 | MTL_ENABLE_DEBUG_INFO = NO; 663 | SDKROOT = iphoneos; 664 | SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; 665 | TARGETED_DEVICE_FAMILY = "1,2"; 666 | VALIDATE_PRODUCT = YES; 667 | VERSIONING_SYSTEM = "apple-generic"; 668 | VERSION_INFO_PREFIX = ""; 669 | }; 670 | name = Release; 671 | }; 672 | A8AFB72319D1401D0070765E /* Debug */ = { 673 | isa = XCBuildConfiguration; 674 | buildSettings = { 675 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; 676 | DEFINES_MODULE = YES; 677 | DYLIB_COMPATIBILITY_VERSION = 1; 678 | DYLIB_CURRENT_VERSION = 1; 679 | DYLIB_INSTALL_NAME_BASE = "@rpath"; 680 | INFOPLIST_FILE = "$(SRCROOT)/Source/Info.plist"; 681 | INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; 682 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 683 | PRODUCT_BUNDLE_IDENTIFIER = "com.swiftjson.$(PRODUCT_NAME:rfc1034identifier)"; 684 | PRODUCT_NAME = "$(TARGET_NAME)"; 685 | SKIP_INSTALL = YES; 686 | SWIFT_VERSION = 3.0; 687 | }; 688 | name = Debug; 689 | }; 690 | A8AFB72419D1401D0070765E /* Release */ = { 691 | isa = XCBuildConfiguration; 692 | buildSettings = { 693 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; 694 | DEFINES_MODULE = YES; 695 | DYLIB_COMPATIBILITY_VERSION = 1; 696 | DYLIB_CURRENT_VERSION = 1; 697 | DYLIB_INSTALL_NAME_BASE = "@rpath"; 698 | INFOPLIST_FILE = "$(SRCROOT)/Source/Info.plist"; 699 | INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; 700 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 701 | PRODUCT_BUNDLE_IDENTIFIER = "com.swiftjson.$(PRODUCT_NAME:rfc1034identifier)"; 702 | PRODUCT_NAME = "$(TARGET_NAME)"; 703 | SKIP_INSTALL = YES; 704 | SWIFT_VERSION = 3.0; 705 | }; 706 | name = Release; 707 | }; 708 | A8AFB72619D1401D0070765E /* Debug */ = { 709 | isa = XCBuildConfiguration; 710 | buildSettings = { 711 | GCC_PREPROCESSOR_DEFINITIONS = ( 712 | "DEBUG=1", 713 | "$(inherited)", 714 | ); 715 | INFOPLIST_FILE = Tests/Info.plist; 716 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 717 | PRODUCT_BUNDLE_IDENTIFIER = "com.swiftjson.$(PRODUCT_NAME:rfc1034identifier)"; 718 | PRODUCT_NAME = "$(TARGET_NAME)"; 719 | SWIFT_VERSION = 3.0; 720 | }; 721 | name = Debug; 722 | }; 723 | A8AFB72719D1401D0070765E /* Release */ = { 724 | isa = XCBuildConfiguration; 725 | buildSettings = { 726 | INFOPLIST_FILE = Tests/Info.plist; 727 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 728 | PRODUCT_BUNDLE_IDENTIFIER = "com.swiftjson.$(PRODUCT_NAME:rfc1034identifier)"; 729 | PRODUCT_NAME = "$(TARGET_NAME)"; 730 | SWIFT_VERSION = 3.0; 731 | }; 732 | name = Release; 733 | }; 734 | /* End XCBuildConfiguration section */ 735 | 736 | /* Begin XCConfigurationList section */ 737 | A8AFB70919D1401D0070765E /* Build configuration list for PBXProject "Alamofire-SwiftyJSON" */ = { 738 | isa = XCConfigurationList; 739 | buildConfigurations = ( 740 | A8AFB72019D1401D0070765E /* Debug */, 741 | A8AFB72119D1401D0070765E /* Release */, 742 | ); 743 | defaultConfigurationIsVisible = 0; 744 | defaultConfigurationName = Release; 745 | }; 746 | A8AFB72219D1401D0070765E /* Build configuration list for PBXNativeTarget "AlamofireSwiftyJSON" */ = { 747 | isa = XCConfigurationList; 748 | buildConfigurations = ( 749 | A8AFB72319D1401D0070765E /* Debug */, 750 | A8AFB72419D1401D0070765E /* Release */, 751 | ); 752 | defaultConfigurationIsVisible = 0; 753 | defaultConfigurationName = Release; 754 | }; 755 | A8AFB72519D1401D0070765E /* Build configuration list for PBXNativeTarget "AlamofireSwiftyJSONTests" */ = { 756 | isa = XCConfigurationList; 757 | buildConfigurations = ( 758 | A8AFB72619D1401D0070765E /* Debug */, 759 | A8AFB72719D1401D0070765E /* Release */, 760 | ); 761 | defaultConfigurationIsVisible = 0; 762 | defaultConfigurationName = Release; 763 | }; 764 | /* End XCConfigurationList section */ 765 | }; 766 | rootObject = A8AFB70619D1401D0070765E /* Project object */; 767 | } 768 | -------------------------------------------------------------------------------- /Alamofire-SwiftyJSON.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /Alamofire-SwiftyJSON.xcodeproj/project.xcworkspace/xcshareddata/Alamofire-SwiftyJSON.xcscmblueprint: -------------------------------------------------------------------------------- 1 | { 2 | "DVTSourceControlWorkspaceBlueprintPrimaryRemoteRepositoryKey" : "79EA0C4F360E98830418AFAE1A03A39D646B0106", 3 | "DVTSourceControlWorkspaceBlueprintWorkingCopyRepositoryLocationsKey" : { 4 | 5 | }, 6 | "DVTSourceControlWorkspaceBlueprintWorkingCopyStatesKey" : { 7 | "67620B5EFA902936DF04070AF595B76AB0333747" : 0, 8 | "C861FC00CEE0F6A6BE81FCFF6785FAA78C58EBB3" : 0, 9 | "79EA0C4F360E98830418AFAE1A03A39D646B0106" : 0 10 | }, 11 | "DVTSourceControlWorkspaceBlueprintIdentifierKey" : "91EDE7D1-24DF-4EB3-99E3-20EFE55617CE", 12 | "DVTSourceControlWorkspaceBlueprintWorkingCopyPathsKey" : { 13 | "67620B5EFA902936DF04070AF595B76AB0333747" : "Alamofire-SwiftyJSON\/Alamofire\/", 14 | "C861FC00CEE0F6A6BE81FCFF6785FAA78C58EBB3" : "Alamofire-SwiftyJSON\/SwiftyJSON\/", 15 | "79EA0C4F360E98830418AFAE1A03A39D646B0106" : "Alamofire-SwiftyJSON\/" 16 | }, 17 | "DVTSourceControlWorkspaceBlueprintNameKey" : "Alamofire-SwiftyJSON", 18 | "DVTSourceControlWorkspaceBlueprintVersion" : 204, 19 | "DVTSourceControlWorkspaceBlueprintRelativePathToProjectKey" : "Alamofire-SwiftyJSON.xcodeproj", 20 | "DVTSourceControlWorkspaceBlueprintRemoteRepositoriesKey" : [ 21 | { 22 | "DVTSourceControlWorkspaceBlueprintRemoteRepositoryURLKey" : "https:\/\/github.com\/Alamofire\/Alamofire.git", 23 | "DVTSourceControlWorkspaceBlueprintRemoteRepositorySystemKey" : "com.apple.dt.Xcode.sourcecontrol.Git", 24 | "DVTSourceControlWorkspaceBlueprintRemoteRepositoryIdentifierKey" : "67620B5EFA902936DF04070AF595B76AB0333747" 25 | }, 26 | { 27 | "DVTSourceControlWorkspaceBlueprintRemoteRepositoryURLKey" : "https:\/\/github.com\/jregnauld\/Alamofire-SwiftyJSON.git", 28 | "DVTSourceControlWorkspaceBlueprintRemoteRepositorySystemKey" : "com.apple.dt.Xcode.sourcecontrol.Git", 29 | "DVTSourceControlWorkspaceBlueprintRemoteRepositoryIdentifierKey" : "79EA0C4F360E98830418AFAE1A03A39D646B0106" 30 | }, 31 | { 32 | "DVTSourceControlWorkspaceBlueprintRemoteRepositoryURLKey" : "https:\/\/github.com\/SwiftyJSON\/SwiftyJSON.git", 33 | "DVTSourceControlWorkspaceBlueprintRemoteRepositorySystemKey" : "com.apple.dt.Xcode.sourcecontrol.Git", 34 | "DVTSourceControlWorkspaceBlueprintRemoteRepositoryIdentifierKey" : "C861FC00CEE0F6A6BE81FCFF6785FAA78C58EBB3" 35 | } 36 | ] 37 | } -------------------------------------------------------------------------------- /Alamofire-SwiftyJSON.xcodeproj/xcshareddata/xcschemes/AlamofireSwiftyJSON.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 29 | 35 | 36 | 37 | 38 | 39 | 45 | 46 | 48 | 54 | 55 | 56 | 57 | 58 | 64 | 65 | 66 | 67 | 68 | 69 | 80 | 81 | 87 | 88 | 89 | 90 | 91 | 92 | 98 | 99 | 105 | 106 | 107 | 108 | 110 | 111 | 114 | 115 | 116 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2014 SwiftyJSON 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | 23 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Alamofire-SwiftyJSON ![](https://travis-ci.org/SwiftyJSON/Alamofire-SwiftyJSON.svg?branch=master) 2 | 3 | An extension to make serializing [Alamofire](https://github.com/Alamofire/Alamofire)'s response with [SwiftyJSON](https://github.com/SwiftyJSON/SwiftyJSON) easily. 4 | 5 | ⚠️ **To use with Swift 3.x please ensure you are using >= `2.0.0`** ⚠️ 6 | 7 | ⚠️ **To use with Swift 4.x please ensure you are using >= `3.0.0`** ⚠️ 8 | 9 | ## Swift version 10 | 11 | Alamofire-SwiftyJSON | Swift version | Alamofire | SwiftyJSON 12 | ------------- | --------------| ----------| ---------- 13 | 2.x | Swift 3.x | 4.x | 3.x 14 | 3.x | Swift 4.x | 4.5.x | 4.x 15 | 16 | ## Requirements 17 | 18 | - iOS 8.0+ / Mac OS X 10.9+ 19 | - Xcode 8.0+ 20 | - Swift 3.0+ 21 | 22 | ## Install 23 | 24 | [CocoaPods](https://cocoapods.org/): 25 | 26 | ```ruby 27 | pod 'Alamofire-SwiftyJSON' 28 | ``` 29 | 30 | [Carthage](https://github.com/Carthage/Carthage): 31 | 32 | ``` 33 | github "SwiftyJSON/Alamofire-SwiftyJSON" "master" 34 | ``` 35 | 36 | ## Usage 37 | ```swift 38 | import Alamofire_SwiftyJSON 39 | ``` 40 | 41 | ```swift 42 | Alamofire.request(URL, method: .get, parameters: parameters, encoding: URLEncoding.default) 43 | .responseSwiftyJSON { dataResponse in 44 | print(dataResponse.request) 45 | print(dataResponse.response) 46 | print(dataResponse.error) 47 | print(dataResponse.value) 48 | }) 49 | ``` 50 | -------------------------------------------------------------------------------- /Source/Alamofire-SwiftyJSON.h: -------------------------------------------------------------------------------- 1 | // 2 | // Alamofire-SwiftyJSON.h 3 | // Alamofire-SwiftyJSON 4 | // 5 | // Created by Pinglin Tang on 14-9-23. 6 | // Copyright (c) 2014年 SwiftJSON. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | //! Project version number for Alamofire-SwiftyJSON. 12 | FOUNDATION_EXPORT double Alamofire_SwiftyJSONVersionNumber; 13 | 14 | //! Project version string for Alamofire-SwiftyJSON. 15 | FOUNDATION_EXPORT const unsigned char Alamofire_SwiftyJSONVersionString[]; 16 | 17 | // In this header, you should import all the public headers of your framework using statements like #import 18 | 19 | 20 | -------------------------------------------------------------------------------- /Source/Alamofire-SwiftyJSON.swift: -------------------------------------------------------------------------------- 1 | // 2 | // AlamofireSwiftyJSON.swift 3 | // AlamofireSwiftyJSON 4 | // 5 | // Created by Pinglin Tang on 14-9-22. 6 | // Copyright (c) 2014 SwiftyJSON. All rights reserved. 7 | // 8 | 9 | import Foundation 10 | 11 | import Alamofire 12 | import SwiftyJSON 13 | 14 | // MARK: - Request for Swift JSON 15 | 16 | extension Request { 17 | /// Returns a SwiftyJSON object contained in a result type constructed from the response data using `JSONSerialization` 18 | /// with the specified reading options. 19 | /// 20 | /// - parameter options: The JSON serialization reading options. Defaults to `.allowFragments`. 21 | /// - parameter response: The response from the server. 22 | /// - parameter data: The data returned from the server. 23 | /// - parameter error: The error already encountered if it exists. 24 | /// 25 | /// - returns: The result data type. 26 | public static func serializeResponseSwiftyJSON( 27 | options: JSONSerialization.ReadingOptions, 28 | response: HTTPURLResponse?, 29 | data: Data?, 30 | error: Error?) 31 | -> Result 32 | { 33 | guard error == nil else { return .failure(error!) } 34 | 35 | if let response = response, emptyDataStatusCodes.contains(response.statusCode) { return .success(JSON.null) } 36 | 37 | guard let validData = data, validData.count > 0 else { 38 | return .failure(AFError.responseSerializationFailed(reason: .inputDataNilOrZeroLength)) 39 | } 40 | 41 | do { 42 | let json = try JSONSerialization.jsonObject(with: validData, options: options) 43 | return .success(JSON(json)) 44 | } catch { 45 | return .failure(AFError.responseSerializationFailed(reason: .jsonSerializationFailed(error: error))) 46 | } 47 | } 48 | } 49 | 50 | extension DataRequest { 51 | /// Creates a response serializer that returns a SwiftyJSON object result type constructed from the response data using 52 | /// `JSONSerialization` with the specified reading options. 53 | /// 54 | /// - parameter options: The JSON serialization reading options. Defaults to `.allowFragments`. 55 | /// 56 | /// - returns: A JSON object response serializer. 57 | public static func swiftyJSONResponseSerializer( 58 | options: JSONSerialization.ReadingOptions = .allowFragments) 59 | -> DataResponseSerializer 60 | { 61 | return DataResponseSerializer { _, response, data, error in 62 | return Request.serializeResponseSwiftyJSON(options: options, response: response, data: data, error: error) 63 | } 64 | } 65 | 66 | /// Adds a handler to be called once the request has finished. 67 | /// 68 | /// - parameter options: The JSON serialization reading options. Defaults to `.allowFragments`. 69 | /// - parameter completionHandler: A closure to be executed once the request has finished. 70 | /// 71 | /// - returns: The request. 72 | @discardableResult 73 | public func responseSwiftyJSON( 74 | queue: DispatchQueue? = nil, 75 | options: JSONSerialization.ReadingOptions = .allowFragments, 76 | completionHandler: @escaping (DataResponse) -> Void) 77 | -> Self 78 | { 79 | return response( 80 | queue: queue, 81 | responseSerializer: DataRequest.swiftyJSONResponseSerializer(options: options), 82 | completionHandler: completionHandler 83 | ) 84 | } 85 | } 86 | 87 | private let emptyDataStatusCodes: Set = [204, 205] 88 | -------------------------------------------------------------------------------- /Source/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIdentifier 10 | $(PRODUCT_BUNDLE_IDENTIFIER) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | $(PRODUCT_NAME) 15 | CFBundlePackageType 16 | FMWK 17 | CFBundleShortVersionString 18 | 3.0.0 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | $(CURRENT_PROJECT_VERSION) 23 | NSPrincipalClass 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /Tests/Alamofire_SwiftyJSONTests.swift: -------------------------------------------------------------------------------- 1 | // 2 | // Alamofire_SwiftyJSONTests.swift 3 | // Alamofire-SwiftyJSONTests 4 | // 5 | // Created by Pinglin Tang on 14-9-23. 6 | // Copyright (c) 2014年 SwiftJSON. All rights reserved. 7 | // 8 | 9 | import XCTest 10 | import Alamofire 11 | import SwiftyJSON 12 | import AlamofireSwiftyJSON 13 | 14 | class Alamofire_SwiftyJSONTests: XCTestCase { 15 | 16 | func testGETRequestJSONResponse() { 17 | let URL = "http://httpbin.org/get" 18 | let parameters: Parameters = ["foo": "bar"] 19 | let expect = expectation(description: "responseSwiftyJSON method should work") 20 | Alamofire.request(URL, method: .get, parameters: parameters, encoding: URLEncoding.default) 21 | .validate() 22 | .responseSwiftyJSON { response in 23 | XCTAssertNotNil(response.request, "request should not be nil") 24 | XCTAssertNotNil(response.response, "response should not be nil") 25 | XCTAssertNil(response.error, "result error should be nil") 26 | XCTAssertEqual(response.value?["args"], SwiftyJSON.JSON(["foo": "bar"] as NSDictionary), "args should be equal") 27 | expect.fulfill() 28 | } 29 | waitForExpectations(timeout: 10.0, handler: nil) 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /Tests/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIdentifier 10 | $(PRODUCT_BUNDLE_IDENTIFIER) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | $(PRODUCT_NAME) 15 | CFBundlePackageType 16 | BNDL 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | 1 23 | 24 | 25 | --------------------------------------------------------------------------------