motion-yapper 0.0.1 → 0.0.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (296) hide show
  1. checksums.yaml +4 -4
  2. data/.gitignore +2 -2
  3. data/.travis.yml +2 -0
  4. data/Gemfile +1 -0
  5. data/README.md +1 -1
  6. data/Rakefile +1 -1
  7. data/lib/motion-yapper.rb +1 -0
  8. data/lib/yapper.rb +3 -5
  9. data/lib/yapper/config.rb +2 -0
  10. data/lib/yapper/db.rb +105 -40
  11. data/lib/yapper/document.rb +7 -4
  12. data/lib/yapper/document/callbacks.rb +0 -7
  13. data/lib/yapper/document/{persistance.rb → persistence.rb} +27 -21
  14. data/lib/yapper/document/relation.rb +29 -22
  15. data/lib/yapper/document/selection.rb +122 -54
  16. data/lib/yapper/extensions.rb +12 -24
  17. data/lib/yapper/settings.rb +43 -0
  18. data/lib/yapper/timestamps.rb +2 -0
  19. data/lib/yapper/version.rb +1 -1
  20. data/{yapper.gemspec → motion-yapper.gemspec} +0 -0
  21. data/spec/integration/{where_spec.rb → criteria_spec.rb} +78 -10
  22. data/spec/integration/db_spec.rb +70 -0
  23. data/spec/integration/defaults_spec.rb +37 -0
  24. data/spec/integration/extensions_spec.rb +14 -0
  25. data/spec/integration/{persistance_spec.rb → persistence_spec.rb} +0 -0
  26. data/spec/integration/relation_spec.rb +4 -4
  27. data/vendor/Podfile.lock +9 -11
  28. data/vendor/Pods/.build/libPods-CocoaLumberjack.a +0 -0
  29. data/vendor/Pods/.build/libPods-NSData+MD5Digest.a +0 -0
  30. data/vendor/Pods/.build/libPods-YapDatabase.a +0 -0
  31. data/vendor/Pods/.build/libPods.a +0 -0
  32. data/vendor/Pods/BuildHeaders/CocoaLumberjack/DDASLLogger.h +4 -4
  33. data/vendor/Pods/BuildHeaders/CocoaLumberjack/DDAbstractDatabaseLogger.h +14 -14
  34. data/vendor/Pods/{CocoaLumberjack/Lumberjack/Extensions/ContextFilterLogFormatter.h → BuildHeaders/CocoaLumberjack/DDContextFilterLogFormatter.h} +6 -8
  35. data/vendor/Pods/BuildHeaders/CocoaLumberjack/{DispatchQueueLogFormatter.h → DDDispatchQueueLogFormatter.h} +18 -6
  36. data/vendor/Pods/BuildHeaders/CocoaLumberjack/DDFileLogger.h +67 -32
  37. data/vendor/Pods/BuildHeaders/CocoaLumberjack/DDLog+LOGV.h +99 -0
  38. data/vendor/Pods/BuildHeaders/CocoaLumberjack/DDLog.h +98 -65
  39. data/vendor/Pods/BuildHeaders/CocoaLumberjack/DDMultiFormatter.h +30 -0
  40. data/vendor/Pods/BuildHeaders/CocoaLumberjack/DDTTYLogger.h +39 -25
  41. data/vendor/Pods/BuildHeaders/YapDatabase/NSDictionary+YapDatabase.h +8 -0
  42. data/vendor/Pods/BuildHeaders/YapDatabase/YapCache.h +1 -0
  43. data/vendor/Pods/BuildHeaders/YapDatabase/YapCollectionKey.h +3 -0
  44. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabase.h +4 -4
  45. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseConnection.h +21 -19
  46. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseDefaults.h +1 -1
  47. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseExtensionPrivate.h +35 -31
  48. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseFilteredView.h +8 -35
  49. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseFilteredViewPrivate.h +0 -2
  50. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseFilteredViewTransaction.h +17 -17
  51. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseFilteredViewTypes.h +32 -0
  52. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseFullTextSearchPrivate.h +8 -0
  53. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabasePrivate.h +43 -21
  54. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseRelationship.h +35 -0
  55. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseRelationshipConnection.h +29 -0
  56. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseRelationshipEdge.h +163 -0
  57. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseRelationshipEdgePrivate.h +79 -0
  58. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseRelationshipNode.h +99 -0
  59. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseRelationshipOptions.h +59 -0
  60. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseRelationshipPrivate.h +125 -0
  61. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseRelationshipTransaction.h +384 -0
  62. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseSecondaryIndex.h +49 -0
  63. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseSecondaryIndexPrivate.h +10 -0
  64. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseSecondaryIndexSetupPrivate.h +18 -0
  65. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseTransaction.h +131 -21
  66. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseView.h +48 -107
  67. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseViewChange.h +2 -2
  68. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseViewConnection.h +1 -0
  69. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseViewMappings.h +17 -0
  70. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseViewOptions.h +10 -3
  71. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseViewPrivate.h +18 -1
  72. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseViewTransaction.h +75 -24
  73. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseViewTypes.h +99 -0
  74. data/vendor/Pods/CocoaLumberjack/Lumberjack/DDASLLogger.h +4 -4
  75. data/vendor/Pods/CocoaLumberjack/Lumberjack/DDASLLogger.m +51 -50
  76. data/vendor/Pods/CocoaLumberjack/Lumberjack/DDAbstractDatabaseLogger.h +14 -14
  77. data/vendor/Pods/CocoaLumberjack/Lumberjack/DDAbstractDatabaseLogger.m +546 -546
  78. data/vendor/Pods/CocoaLumberjack/Lumberjack/DDFileLogger.h +67 -32
  79. data/vendor/Pods/CocoaLumberjack/Lumberjack/DDFileLogger.m +1093 -907
  80. data/vendor/Pods/CocoaLumberjack/Lumberjack/DDLog+LOGV.h +99 -0
  81. data/vendor/Pods/CocoaLumberjack/Lumberjack/DDLog.h +98 -65
  82. data/vendor/Pods/CocoaLumberjack/Lumberjack/DDLog.m +873 -748
  83. data/vendor/Pods/CocoaLumberjack/Lumberjack/DDTTYLogger.h +39 -25
  84. data/vendor/Pods/CocoaLumberjack/Lumberjack/DDTTYLogger.m +1284 -1243
  85. data/vendor/Pods/{BuildHeaders/CocoaLumberjack/ContextFilterLogFormatter.h → CocoaLumberjack/Lumberjack/Extensions/DDContextFilterLogFormatter.h} +6 -8
  86. data/vendor/Pods/CocoaLumberjack/Lumberjack/Extensions/{ContextFilterLogFormatter.m → DDContextFilterLogFormatter.m} +70 -70
  87. data/vendor/Pods/CocoaLumberjack/Lumberjack/Extensions/{DispatchQueueLogFormatter.h → DDDispatchQueueLogFormatter.h} +18 -6
  88. data/vendor/Pods/CocoaLumberjack/Lumberjack/Extensions/DDDispatchQueueLogFormatter.m +253 -0
  89. data/vendor/Pods/CocoaLumberjack/Lumberjack/Extensions/DDMultiFormatter.h +30 -0
  90. data/vendor/Pods/CocoaLumberjack/Lumberjack/Extensions/DDMultiFormatter.m +127 -0
  91. data/vendor/Pods/CocoaLumberjack/Lumberjack/Extensions/README.txt +1 -1
  92. data/vendor/Pods/CocoaLumberjack/README.markdown +52 -15
  93. data/vendor/Pods/Headers/CocoaLumberjack/DDASLLogger.h +4 -4
  94. data/vendor/Pods/Headers/CocoaLumberjack/DDAbstractDatabaseLogger.h +14 -14
  95. data/vendor/Pods/Headers/CocoaLumberjack/{ContextFilterLogFormatter.h → DDContextFilterLogFormatter.h} +6 -8
  96. data/vendor/Pods/Headers/CocoaLumberjack/{DispatchQueueLogFormatter.h → DDDispatchQueueLogFormatter.h} +18 -6
  97. data/vendor/Pods/Headers/CocoaLumberjack/DDFileLogger.h +67 -32
  98. data/vendor/Pods/Headers/CocoaLumberjack/DDLog+LOGV.h +99 -0
  99. data/vendor/Pods/Headers/CocoaLumberjack/DDLog.h +98 -65
  100. data/vendor/Pods/Headers/CocoaLumberjack/DDMultiFormatter.h +30 -0
  101. data/vendor/Pods/Headers/CocoaLumberjack/DDTTYLogger.h +39 -25
  102. data/vendor/Pods/Headers/YapDatabase/YapCollectionKey.h +3 -0
  103. data/vendor/Pods/Headers/YapDatabase/YapDatabase.h +4 -4
  104. data/vendor/Pods/Headers/YapDatabase/YapDatabaseConnection.h +21 -19
  105. data/vendor/Pods/Headers/YapDatabase/YapDatabaseFilteredView.h +8 -35
  106. data/vendor/Pods/Headers/YapDatabase/YapDatabaseFilteredViewTransaction.h +17 -17
  107. data/vendor/Pods/Headers/YapDatabase/YapDatabaseFilteredViewTypes.h +32 -0
  108. data/vendor/Pods/Headers/YapDatabase/YapDatabaseRelationship.h +35 -0
  109. data/vendor/Pods/Headers/YapDatabase/YapDatabaseRelationshipConnection.h +29 -0
  110. data/vendor/Pods/Headers/YapDatabase/YapDatabaseRelationshipEdge.h +163 -0
  111. data/vendor/Pods/Headers/YapDatabase/YapDatabaseRelationshipNode.h +99 -0
  112. data/vendor/Pods/Headers/YapDatabase/YapDatabaseRelationshipOptions.h +59 -0
  113. data/vendor/Pods/Headers/YapDatabase/YapDatabaseRelationshipTransaction.h +384 -0
  114. data/vendor/Pods/Headers/YapDatabase/YapDatabaseSecondaryIndex.h +49 -0
  115. data/vendor/Pods/Headers/YapDatabase/YapDatabaseTransaction.h +131 -21
  116. data/vendor/Pods/Headers/YapDatabase/YapDatabaseView.h +48 -107
  117. data/vendor/Pods/Headers/YapDatabase/YapDatabaseViewChange.h +2 -2
  118. data/vendor/Pods/Headers/YapDatabase/YapDatabaseViewConnection.h +1 -0
  119. data/vendor/Pods/Headers/YapDatabase/YapDatabaseViewMappings.h +17 -0
  120. data/vendor/Pods/Headers/YapDatabase/YapDatabaseViewOptions.h +10 -3
  121. data/vendor/Pods/Headers/YapDatabase/YapDatabaseViewTransaction.h +75 -24
  122. data/vendor/Pods/Headers/YapDatabase/YapDatabaseViewTypes.h +99 -0
  123. data/vendor/Pods/Headers/____Pods-CocoaLumberjack-prefix.h +2 -0
  124. data/vendor/Pods/Headers/____Pods-environment.h +15 -15
  125. data/vendor/Pods/Manifest.lock +9 -11
  126. data/vendor/Pods/Pods-CocoaLumberjack-Private.xcconfig +1 -1
  127. data/vendor/Pods/Pods-CocoaLumberjack-prefix.pch +2 -0
  128. data/vendor/Pods/Pods-NSData+MD5Digest-Private.xcconfig +1 -1
  129. data/vendor/Pods/Pods-YapDatabase-Private.xcconfig +1 -1
  130. data/vendor/Pods/{Pods-Acknowledgements.markdown → Pods-acknowledgements.markdown} +0 -37
  131. data/vendor/Pods/{Pods-Acknowledgements.plist → Pods-acknowledgements.plist} +0 -45
  132. data/vendor/Pods/Pods-environment.h +15 -15
  133. data/vendor/Pods/Pods.xcconfig +3 -3
  134. data/vendor/Pods/Pods.xcodeproj/project.pbxproj +2426 -3155
  135. data/vendor/Pods/Pods.xcodeproj/xcuserdata/kareemk.xcuserdatad/xcschemes/Pods-CocoaLumberjack.xcscheme +59 -0
  136. data/vendor/Pods/Pods.xcodeproj/xcuserdata/kareemk.xcuserdatad/xcschemes/Pods-NSData+MD5Digest.xcscheme +59 -0
  137. data/vendor/Pods/Pods.xcodeproj/xcuserdata/kareemk.xcuserdatad/xcschemes/Pods-YapDatabase.xcscheme +59 -0
  138. data/vendor/Pods/Pods.xcodeproj/xcuserdata/kareemk.xcuserdatad/xcschemes/Pods.xcscheme +59 -0
  139. data/vendor/Pods/Pods.xcodeproj/xcuserdata/kareemk.xcuserdatad/xcschemes/xcschememanagement.plist +31 -0
  140. data/vendor/Pods/YapDatabase/README.md +3 -1
  141. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/FilteredViews/Internal/YapDatabaseFilteredViewPrivate.h +0 -2
  142. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/FilteredViews/YapDatabaseFilteredView.h +8 -35
  143. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/FilteredViews/YapDatabaseFilteredView.m +25 -41
  144. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/FilteredViews/YapDatabaseFilteredViewTransaction.h +17 -17
  145. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/FilteredViews/YapDatabaseFilteredViewTransaction.m +403 -134
  146. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/FilteredViews/YapDatabaseFilteredViewTypes.h +32 -0
  147. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/FullTextSearch/Internal/YapDatabaseFullTextSearchPrivate.h +8 -0
  148. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/FullTextSearch/YapDatabaseFullTextSearchConnection.m +8 -8
  149. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/FullTextSearch/YapDatabaseFullTextSearchTransaction.m +113 -62
  150. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Protocol/Internal/YapDatabaseExtensionPrivate.h +35 -31
  151. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Protocol/YapDatabaseExtension.m +25 -0
  152. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Protocol/YapDatabaseExtensionConnection.m +1 -1
  153. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Protocol/YapDatabaseExtensionTransaction.m +25 -1
  154. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Relationships/Internal/YapDatabaseRelationshipEdgePrivate.h +79 -0
  155. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Relationships/Internal/YapDatabaseRelationshipPrivate.h +125 -0
  156. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Relationships/YapDatabaseRelationship.h +35 -0
  157. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Relationships/YapDatabaseRelationship.m +129 -0
  158. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Relationships/YapDatabaseRelationshipConnection.h +29 -0
  159. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Relationships/YapDatabaseRelationshipConnection.m +802 -0
  160. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Relationships/YapDatabaseRelationshipEdge.h +163 -0
  161. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Relationships/YapDatabaseRelationshipEdge.m +408 -0
  162. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Relationships/YapDatabaseRelationshipNode.h +99 -0
  163. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Relationships/YapDatabaseRelationshipOptions.h +59 -0
  164. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Relationships/YapDatabaseRelationshipOptions.m +29 -0
  165. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Relationships/YapDatabaseRelationshipTransaction.h +384 -0
  166. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Relationships/YapDatabaseRelationshipTransaction.m +5254 -0
  167. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/SecondaryIndex/Internal/YapDatabaseSecondaryIndexPrivate.h +10 -0
  168. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/SecondaryIndex/Internal/YapDatabaseSecondaryIndexSetupPrivate.h +18 -0
  169. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/SecondaryIndex/YapDatabaseSecondaryIndex.h +49 -0
  170. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/SecondaryIndex/YapDatabaseSecondaryIndex.m +12 -0
  171. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/SecondaryIndex/YapDatabaseSecondaryIndexConnection.m +9 -8
  172. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/SecondaryIndex/YapDatabaseSecondaryIndexSetup.m +62 -1
  173. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/SecondaryIndex/YapDatabaseSecondaryIndexTransaction.m +148 -45
  174. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Views/Internal/YapDatabaseViewPrivate.h +18 -1
  175. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Views/Utilities/YapDatabaseViewChange.h +2 -2
  176. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Views/Utilities/YapDatabaseViewChange.m +15 -9
  177. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Views/Utilities/YapDatabaseViewMappings.h +17 -0
  178. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Views/Utilities/YapDatabaseViewMappings.m +211 -64
  179. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Views/YapDatabaseView.h +48 -107
  180. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Views/YapDatabaseView.m +10 -7
  181. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Views/YapDatabaseViewConnection.h +1 -0
  182. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Views/YapDatabaseViewConnection.m +13 -22
  183. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Views/YapDatabaseViewOptions.h +10 -3
  184. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Views/YapDatabaseViewTransaction.h +75 -24
  185. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Views/YapDatabaseViewTransaction.m +725 -244
  186. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Views/YapDatabaseViewTypes.h +99 -0
  187. data/vendor/Pods/YapDatabase/YapDatabase/Internal/NSDictionary+YapDatabase.h +8 -0
  188. data/vendor/Pods/YapDatabase/YapDatabase/Internal/NSDictionary+YapDatabase.m +19 -0
  189. data/vendor/Pods/YapDatabase/YapDatabase/Internal/YapCache.h +1 -0
  190. data/vendor/Pods/YapDatabase/YapDatabase/Internal/YapCache.m +12 -0
  191. data/vendor/Pods/YapDatabase/YapDatabase/Internal/YapDatabaseDefaults.h +1 -1
  192. data/vendor/Pods/YapDatabase/YapDatabase/Internal/YapDatabaseDefaults.m +3 -3
  193. data/vendor/Pods/YapDatabase/YapDatabase/Internal/YapDatabasePrivate.h +43 -21
  194. data/vendor/Pods/YapDatabase/YapDatabase/Internal/YapNull.m +4 -0
  195. data/vendor/Pods/YapDatabase/YapDatabase/Utilities/YapCollectionKey.h +3 -0
  196. data/vendor/Pods/YapDatabase/YapDatabase/Utilities/YapCollectionKey.m +5 -0
  197. data/vendor/Pods/YapDatabase/YapDatabase/YapDatabase.h +4 -4
  198. data/vendor/Pods/YapDatabase/YapDatabase/YapDatabase.m +84 -93
  199. data/vendor/Pods/YapDatabase/YapDatabase/YapDatabaseConnection.h +21 -19
  200. data/vendor/Pods/YapDatabase/YapDatabase/YapDatabaseConnection.m +381 -209
  201. data/vendor/Pods/YapDatabase/YapDatabase/YapDatabaseTransaction.h +131 -21
  202. data/vendor/Pods/YapDatabase/YapDatabase/YapDatabaseTransaction.m +587 -267
  203. data/vendor/Pods/{Pods.bridgesupport → build-iPhoneSimulator/Pods.bridgesupport} +633 -2557
  204. data/vendor/Pods/build-iPhoneSimulator/libPods.a +0 -0
  205. data/vendor/YapDatabaseRubyMotion/YapDatabaseRubyMotion.bridgesupport +2 -1
  206. data/vendor/YapDatabaseRubyMotion/YapDatabaseRubyMotion.h +2 -1
  207. data/vendor/YapDatabaseRubyMotion/YapDatabaseRubyMotion.m +4 -2
  208. metadata +80 -108
  209. data/Gemfile.lock +0 -63
  210. data/lib/yapper/attachment.rb +0 -48
  211. data/lib/yapper/document/attachment.rb +0 -26
  212. data/lib/yapper/sync.rb +0 -134
  213. data/lib/yapper/sync/data.rb +0 -12
  214. data/lib/yapper/sync/event.rb +0 -194
  215. data/lib/yapper/sync/queue.rb +0 -164
  216. data/spec/integration/all_spec.rb +0 -40
  217. data/spec/integration/sync_spec.rb +0 -42
  218. data/vendor/Pods/AFNetworking/AFNetworking/AFHTTPClient.h +0 -641
  219. data/vendor/Pods/AFNetworking/AFNetworking/AFHTTPClient.m +0 -1396
  220. data/vendor/Pods/AFNetworking/AFNetworking/AFHTTPRequestOperation.h +0 -133
  221. data/vendor/Pods/AFNetworking/AFNetworking/AFHTTPRequestOperation.m +0 -327
  222. data/vendor/Pods/AFNetworking/AFNetworking/AFImageRequestOperation.h +0 -113
  223. data/vendor/Pods/AFNetworking/AFNetworking/AFImageRequestOperation.m +0 -321
  224. data/vendor/Pods/AFNetworking/AFNetworking/AFJSONRequestOperation.h +0 -71
  225. data/vendor/Pods/AFNetworking/AFNetworking/AFJSONRequestOperation.m +0 -150
  226. data/vendor/Pods/AFNetworking/AFNetworking/AFNetworkActivityIndicatorManager.h +0 -75
  227. data/vendor/Pods/AFNetworking/AFNetworking/AFNetworkActivityIndicatorManager.m +0 -157
  228. data/vendor/Pods/AFNetworking/AFNetworking/AFNetworking.h +0 -43
  229. data/vendor/Pods/AFNetworking/AFNetworking/AFPropertyListRequestOperation.h +0 -68
  230. data/vendor/Pods/AFNetworking/AFNetworking/AFPropertyListRequestOperation.m +0 -143
  231. data/vendor/Pods/AFNetworking/AFNetworking/AFURLConnectionOperation.h +0 -370
  232. data/vendor/Pods/AFNetworking/AFNetworking/AFURLConnectionOperation.m +0 -848
  233. data/vendor/Pods/AFNetworking/AFNetworking/AFXMLRequestOperation.h +0 -89
  234. data/vendor/Pods/AFNetworking/AFNetworking/AFXMLRequestOperation.m +0 -167
  235. data/vendor/Pods/AFNetworking/AFNetworking/UIImageView+AFNetworking.h +0 -78
  236. data/vendor/Pods/AFNetworking/AFNetworking/UIImageView+AFNetworking.m +0 -191
  237. data/vendor/Pods/AFNetworking/LICENSE +0 -19
  238. data/vendor/Pods/AFNetworking/README.md +0 -208
  239. data/vendor/Pods/BuildHeaders/AFNetworking/AFHTTPClient.h +0 -641
  240. data/vendor/Pods/BuildHeaders/AFNetworking/AFHTTPRequestOperation.h +0 -133
  241. data/vendor/Pods/BuildHeaders/AFNetworking/AFImageRequestOperation.h +0 -113
  242. data/vendor/Pods/BuildHeaders/AFNetworking/AFJSONRequestOperation.h +0 -71
  243. data/vendor/Pods/BuildHeaders/AFNetworking/AFNetworkActivityIndicatorManager.h +0 -75
  244. data/vendor/Pods/BuildHeaders/AFNetworking/AFNetworking.h +0 -43
  245. data/vendor/Pods/BuildHeaders/AFNetworking/AFPropertyListRequestOperation.h +0 -68
  246. data/vendor/Pods/BuildHeaders/AFNetworking/AFURLConnectionOperation.h +0 -370
  247. data/vendor/Pods/BuildHeaders/AFNetworking/AFXMLRequestOperation.h +0 -89
  248. data/vendor/Pods/BuildHeaders/AFNetworking/UIImageView+AFNetworking.h +0 -78
  249. data/vendor/Pods/BuildHeaders/Reachability/Reachability.h +0 -109
  250. data/vendor/Pods/CocoaLumberjack/Lumberjack/Extensions/DispatchQueueLogFormatter.m +0 -251
  251. data/vendor/Pods/Headers/AFNetworking/AFHTTPClient.h +0 -641
  252. data/vendor/Pods/Headers/AFNetworking/AFHTTPRequestOperation.h +0 -133
  253. data/vendor/Pods/Headers/AFNetworking/AFImageRequestOperation.h +0 -113
  254. data/vendor/Pods/Headers/AFNetworking/AFJSONRequestOperation.h +0 -71
  255. data/vendor/Pods/Headers/AFNetworking/AFNetworkActivityIndicatorManager.h +0 -75
  256. data/vendor/Pods/Headers/AFNetworking/AFNetworking.h +0 -43
  257. data/vendor/Pods/Headers/AFNetworking/AFPropertyListRequestOperation.h +0 -68
  258. data/vendor/Pods/Headers/AFNetworking/AFURLConnectionOperation.h +0 -370
  259. data/vendor/Pods/Headers/AFNetworking/AFXMLRequestOperation.h +0 -89
  260. data/vendor/Pods/Headers/AFNetworking/UIImageView+AFNetworking.h +0 -78
  261. data/vendor/Pods/Headers/Reachability/Reachability.h +0 -109
  262. data/vendor/Pods/Headers/YapDatabase/YapCache.h +0 -90
  263. data/vendor/Pods/Headers/YapDatabase/YapDatabaseConnectionState.h +0 -29
  264. data/vendor/Pods/Headers/YapDatabase/YapDatabaseDefaults.h +0 -37
  265. data/vendor/Pods/Headers/YapDatabase/YapDatabaseExtensionPrivate.h +0 -440
  266. data/vendor/Pods/Headers/YapDatabase/YapDatabaseFilteredViewPrivate.h +0 -19
  267. data/vendor/Pods/Headers/YapDatabase/YapDatabaseFullTextSearchPrivate.h +0 -69
  268. data/vendor/Pods/Headers/YapDatabase/YapDatabaseLogging.h +0 -158
  269. data/vendor/Pods/Headers/YapDatabase/YapDatabaseManager.h +0 -17
  270. data/vendor/Pods/Headers/YapDatabase/YapDatabasePrivate.h +0 -424
  271. data/vendor/Pods/Headers/YapDatabase/YapDatabaseSecondaryIndexPrivate.h +0 -73
  272. data/vendor/Pods/Headers/YapDatabase/YapDatabaseStatement.h +0 -13
  273. data/vendor/Pods/Headers/YapDatabase/YapDatabaseString.h +0 -121
  274. data/vendor/Pods/Headers/YapDatabase/YapDatabaseViewChangePrivate.h +0 -94
  275. data/vendor/Pods/Headers/YapDatabase/YapDatabaseViewMappingsPrivate.h +0 -72
  276. data/vendor/Pods/Headers/YapDatabase/YapDatabaseViewPage.h +0 -36
  277. data/vendor/Pods/Headers/YapDatabase/YapDatabaseViewPageMetadata.h +0 -27
  278. data/vendor/Pods/Headers/YapDatabase/YapDatabaseViewPrivate.h +0 -153
  279. data/vendor/Pods/Headers/YapDatabase/YapDatabaseViewRangeOptionsPrivate.h +0 -17
  280. data/vendor/Pods/Headers/YapDatabase/YapMemoryTable.h +0 -74
  281. data/vendor/Pods/Headers/YapDatabase/YapNull.h +0 -17
  282. data/vendor/Pods/Headers/YapDatabase/YapTouch.h +0 -15
  283. data/vendor/Pods/Headers/____Pods-AFNetworking-prefix.h +0 -17
  284. data/vendor/Pods/Headers/____Pods-Reachability-prefix.h +0 -5
  285. data/vendor/Pods/Pods-AFNetworking-Private.xcconfig +0 -5
  286. data/vendor/Pods/Pods-AFNetworking-dummy.m +0 -5
  287. data/vendor/Pods/Pods-AFNetworking-prefix.pch +0 -17
  288. data/vendor/Pods/Pods-AFNetworking.xcconfig +0 -1
  289. data/vendor/Pods/Pods-Reachability-Private.xcconfig +0 -5
  290. data/vendor/Pods/Pods-Reachability-dummy.m +0 -5
  291. data/vendor/Pods/Pods-Reachability-prefix.pch +0 -5
  292. data/vendor/Pods/Pods-Reachability.xcconfig +0 -1
  293. data/vendor/Pods/Reachability/LICENCE.txt +0 -24
  294. data/vendor/Pods/Reachability/README.md +0 -65
  295. data/vendor/Pods/Reachability/Reachability.h +0 -109
  296. data/vendor/Pods/Reachability/Reachability.m +0 -527
@@ -1,370 +0,0 @@
1
- // AFURLConnectionOperation.h
2
- //
3
- // Copyright (c) 2011 Gowalla (http://gowalla.com/)
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
13
- // all 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
21
- // THE SOFTWARE.
22
-
23
- #import <Foundation/Foundation.h>
24
-
25
- #import <Availability.h>
26
-
27
- /**
28
- `AFURLConnectionOperation` is a subclass of `NSOperation` that implements `NSURLConnection` delegate methods.
29
-
30
- ## Subclassing Notes
31
-
32
- This is the base class of all network request operations. You may wish to create your own subclass in order to implement additional `NSURLConnection` delegate methods (see "`NSURLConnection` Delegate Methods" below), or to provide additional properties and/or class constructors.
33
-
34
- If you are creating a subclass that communicates over the HTTP or HTTPS protocols, you may want to consider subclassing `AFHTTPRequestOperation` instead, as it supports specifying acceptable content types or status codes.
35
-
36
- ## NSURLConnection Delegate Methods
37
-
38
- `AFURLConnectionOperation` implements the following `NSURLConnection` delegate methods:
39
-
40
- - `connection:didReceiveResponse:`
41
- - `connection:didReceiveData:`
42
- - `connectionDidFinishLoading:`
43
- - `connection:didFailWithError:`
44
- - `connection:didSendBodyData:totalBytesWritten:totalBytesExpectedToWrite:`
45
- - `connection:willCacheResponse:`
46
- - `connectionShouldUseCredentialStorage:`
47
- - `connection:willSendRequestForAuthenticationChallenge:`
48
-
49
- If any of these methods are overridden in a subclass, they _must_ call the `super` implementation first.
50
-
51
- ## Class Constructors
52
-
53
- Class constructors, or methods that return an unowned instance, are the preferred way for subclasses to encapsulate any particular logic for handling the setup or parsing of response data. For instance, `AFJSONRequestOperation` provides `JSONRequestOperationWithRequest:success:failure:`, which takes block arguments, whose parameter on for a successful request is the JSON object initialized from the `response data`.
54
-
55
- ## Callbacks and Completion Blocks
56
-
57
- The built-in `completionBlock` provided by `NSOperation` allows for custom behavior to be executed after the request finishes. It is a common pattern for class constructors in subclasses to take callback block parameters, and execute them conditionally in the body of its `completionBlock`. Make sure to handle cancelled operations appropriately when setting a `completionBlock` (i.e. returning early before parsing response data). See the implementation of any of the `AFHTTPRequestOperation` subclasses for an example of this.
58
-
59
- Subclasses are strongly discouraged from overriding `setCompletionBlock:`, as `AFURLConnectionOperation`'s implementation includes a workaround to mitigate retain cycles, and what Apple rather ominously refers to as ["The Deallocation Problem"](http://developer.apple.com/library/ios/#technotes/tn2109/).
60
-
61
- ## SSL Pinning
62
-
63
- Relying on the CA trust model to validate SSL certificates exposes your app to security vulnerabilities, such as man-in-the-middle attacks. For applications that connect to known servers, SSL certificate pinning provides an increased level of security, by checking server certificate validity against those specified in the app bundle.
64
-
65
- SSL with certificate pinning is strongly recommended for any application that transmits sensitive information to an external webservice.
66
-
67
- When `defaultSSLPinningMode` is defined on `AFHTTPClient` and the Security framework is linked, connections will be validated on all matching certificates with a `.cer` extension in the bundle root.
68
-
69
- ## NSCoding & NSCopying Conformance
70
-
71
- `AFURLConnectionOperation` conforms to the `NSCoding` and `NSCopying` protocols, allowing operations to be archived to disk, and copied in memory, respectively. However, because of the intrinsic limitations of capturing the exact state of an operation at a particular moment, there are some important caveats to keep in mind:
72
-
73
- ### NSCoding Caveats
74
-
75
- - Encoded operations do not include any block or stream properties. Be sure to set `completionBlock`, `outputStream`, and any callback blocks as necessary when using `-initWithCoder:` or `NSKeyedUnarchiver`.
76
- - Operations are paused on `encodeWithCoder:`. If the operation was encoded while paused or still executing, its archived state will return `YES` for `isReady`. Otherwise, the state of an operation when encoding will remain unchanged.
77
-
78
- ### NSCopying Caveats
79
-
80
- - `-copy` and `-copyWithZone:` return a new operation with the `NSURLRequest` of the original. So rather than an exact copy of the operation at that particular instant, the copying mechanism returns a completely new instance, which can be useful for retrying operations.
81
- - A copy of an operation will not include the `outputStream` of the original.
82
- - Operation copies do not include `completionBlock`. `completionBlock` often strongly captures a reference to `self`, which would otherwise have the unintuitive side-effect of pointing to the _original_ operation when copied.
83
- */
84
-
85
- typedef enum {
86
- AFSSLPinningModeNone,
87
- AFSSLPinningModePublicKey,
88
- AFSSLPinningModeCertificate,
89
- } AFURLConnectionOperationSSLPinningMode;
90
-
91
- @interface AFURLConnectionOperation : NSOperation <NSURLConnectionDelegate,
92
- #if (defined(__IPHONE_OS_VERSION_MIN_REQUIRED) && __IPHONE_OS_VERSION_MIN_REQUIRED >= 50000) || \
93
- (defined(__MAC_OS_X_VERSION_MIN_REQUIRED) && __MAC_OS_X_VERSION_MIN_REQUIRED >= 1080)
94
- NSURLConnectionDataDelegate,
95
- #endif
96
- NSCoding, NSCopying>
97
-
98
- ///-------------------------------
99
- /// @name Accessing Run Loop Modes
100
- ///-------------------------------
101
-
102
- /**
103
- The run loop modes in which the operation will run on the network thread. By default, this is a single-member set containing `NSRunLoopCommonModes`.
104
- */
105
- @property (nonatomic, strong) NSSet *runLoopModes;
106
-
107
- ///-----------------------------------------
108
- /// @name Getting URL Connection Information
109
- ///-----------------------------------------
110
-
111
- /**
112
- The request used by the operation's connection.
113
- */
114
- @property (readonly, nonatomic, strong) NSURLRequest *request;
115
-
116
- /**
117
- The last response received by the operation's connection.
118
- */
119
- @property (readonly, nonatomic, strong) NSURLResponse *response;
120
-
121
- /**
122
- The error, if any, that occurred in the lifecycle of the request.
123
- */
124
- @property (readonly, nonatomic, strong) NSError *error;
125
-
126
- /**
127
- Whether the connection should accept an invalid SSL certificate.
128
-
129
- If `_AFNETWORKING_ALLOW_INVALID_SSL_CERTIFICATES_` is set, this property defaults to `YES` for backwards compatibility. Otherwise, this property defaults to `NO`.
130
- */
131
- @property (nonatomic, assign) BOOL allowsInvalidSSLCertificate;
132
-
133
- ///----------------------------
134
- /// @name Getting Response Data
135
- ///----------------------------
136
-
137
- /**
138
- The data received during the request.
139
- */
140
- @property (readonly, nonatomic, strong) NSData *responseData;
141
-
142
- /**
143
- The string representation of the response data.
144
- */
145
- @property (readonly, nonatomic, copy) NSString *responseString;
146
-
147
- /**
148
- The string encoding of the response.
149
-
150
- If the response does not specify a valid string encoding, `responseStringEncoding` will return `NSUTF8StringEncoding`.
151
- */
152
- @property (readonly, nonatomic, assign) NSStringEncoding responseStringEncoding;
153
-
154
- ///-------------------------------
155
- /// @name Managing URL Credentials
156
- ///-------------------------------
157
-
158
- /**
159
- Whether the URL connection should consult the credential storage for authenticating the connection. `YES` by default.
160
-
161
- This is the value that is returned in the `NSURLConnectionDelegate` method `-connectionShouldUseCredentialStorage:`.
162
- */
163
- @property (nonatomic, assign) BOOL shouldUseCredentialStorage;
164
-
165
- /**
166
- The credential used for authentication challenges in `-connection:didReceiveAuthenticationChallenge:`.
167
-
168
- This will be overridden by any shared credentials that exist for the username or password of the request URL, if present.
169
- */
170
- @property (nonatomic, strong) NSURLCredential *credential;
171
-
172
- /**
173
- The pinning mode which will be used for SSL connections. `AFSSLPinningModePublicKey` by default.
174
-
175
- SSL Pinning requires that the Security framework is linked with the binary. See the "SSL Pinning" section in the `AFURLConnectionOperation`" header for more information.
176
- */
177
- @property (nonatomic, assign) AFURLConnectionOperationSSLPinningMode SSLPinningMode;
178
-
179
- ///------------------------
180
- /// @name Accessing Streams
181
- ///------------------------
182
-
183
- /**
184
- The input stream used to read data to be sent during the request.
185
-
186
- This property acts as a proxy to the `HTTPBodyStream` property of `request`.
187
- */
188
- @property (nonatomic, strong) NSInputStream *inputStream;
189
-
190
- /**
191
- The output stream that is used to write data received until the request is finished.
192
-
193
- By default, data is accumulated into a buffer that is stored into `responseData` upon completion of the request. When `outputStream` is set, the data will not be accumulated into an internal buffer, and as a result, the `responseData` property of the completed request will be `nil`. The output stream will be scheduled in the network thread runloop upon being set.
194
- */
195
- @property (nonatomic, strong) NSOutputStream *outputStream;
196
-
197
- ///---------------------------------------------
198
- /// @name Managing Request Operation Information
199
- ///---------------------------------------------
200
-
201
- /**
202
- The user info dictionary for the receiver.
203
- */
204
- @property (nonatomic, strong) NSDictionary *userInfo;
205
-
206
- ///------------------------------------------------------
207
- /// @name Initializing an AFURLConnectionOperation Object
208
- ///------------------------------------------------------
209
-
210
- /**
211
- Initializes and returns a newly allocated operation object with a url connection configured with the specified url request.
212
-
213
- This is the designated initializer.
214
-
215
- @param urlRequest The request object to be used by the operation connection.
216
- */
217
- - (id)initWithRequest:(NSURLRequest *)urlRequest;
218
-
219
- ///----------------------------------
220
- /// @name Pausing / Resuming Requests
221
- ///----------------------------------
222
-
223
- /**
224
- Pauses the execution of the request operation.
225
-
226
- A paused operation returns `NO` for `-isReady`, `-isExecuting`, and `-isFinished`. As such, it will remain in an `NSOperationQueue` until it is either cancelled or resumed. Pausing a finished, cancelled, or paused operation has no effect.
227
- */
228
- - (void)pause;
229
-
230
- /**
231
- Whether the request operation is currently paused.
232
-
233
- @return `YES` if the operation is currently paused, otherwise `NO`.
234
- */
235
- - (BOOL)isPaused;
236
-
237
- /**
238
- Resumes the execution of the paused request operation.
239
-
240
- Pause/Resume behavior varies depending on the underlying implementation for the operation class. In its base implementation, resuming a paused requests restarts the original request. However, since HTTP defines a specification for how to request a specific content range, `AFHTTPRequestOperation` will resume downloading the request from where it left off, instead of restarting the original request.
241
- */
242
- - (void)resume;
243
-
244
- ///----------------------------------------------
245
- /// @name Configuring Backgrounding Task Behavior
246
- ///----------------------------------------------
247
-
248
- /**
249
- Specifies that the operation should continue execution after the app has entered the background, and the expiration handler for that background task.
250
-
251
- @param handler A handler to be called shortly before the application’s remaining background time reaches 0. The handler is wrapped in a block that cancels the operation, and cleans up and marks the end of execution, unlike the `handler` parameter in `UIApplication -beginBackgroundTaskWithExpirationHandler:`, which expects this to be done in the handler itself. The handler is called synchronously on the main thread, thus blocking the application’s suspension momentarily while the application is notified.
252
- */
253
- #if defined(__IPHONE_OS_VERSION_MIN_REQUIRED)
254
- - (void)setShouldExecuteAsBackgroundTaskWithExpirationHandler:(void (^)(void))handler;
255
- #endif
256
-
257
- ///---------------------------------
258
- /// @name Setting Progress Callbacks
259
- ///---------------------------------
260
-
261
- /**
262
- Sets a callback to be called when an undetermined number of bytes have been uploaded to the server.
263
-
264
- @param block A block object to be called when an undetermined number of bytes have been uploaded to the server. This block has no return value and takes three arguments: the number of bytes written since the last time the upload progress block was called, the total bytes written, and the total bytes expected to be written during the request, as initially determined by the length of the HTTP body. This block may be called multiple times, and will execute on the main thread.
265
- */
266
- - (void)setUploadProgressBlock:(void (^)(NSUInteger bytesWritten, long long totalBytesWritten, long long totalBytesExpectedToWrite))block;
267
-
268
- /**
269
- Sets a callback to be called when an undetermined number of bytes have been downloaded from the server.
270
-
271
- @param block A block object to be called when an undetermined number of bytes have been downloaded from the server. This block has no return value and takes three arguments: the number of bytes read since the last time the download progress block was called, the total bytes read, and the total bytes expected to be read during the request, as initially determined by the expected content size of the `NSHTTPURLResponse` object. This block may be called multiple times, and will execute on the main thread.
272
- */
273
- - (void)setDownloadProgressBlock:(void (^)(NSUInteger bytesRead, long long totalBytesRead, long long totalBytesExpectedToRead))block;
274
-
275
- ///-------------------------------------------------
276
- /// @name Setting NSURLConnection Delegate Callbacks
277
- ///-------------------------------------------------
278
-
279
- /**
280
- Sets a block to be executed when the connection will authenticate a challenge in order to download its request, as handled by the `NSURLConnectionDelegate` method `connection:willSendRequestForAuthenticationChallenge:`.
281
-
282
- @param block A block object to be executed when the connection will authenticate a challenge in order to download its request. The block has no return type and takes two arguments: the URL connection object, and the challenge that must be authenticated. This block must invoke one of the challenge-responder methods (NSURLAuthenticationChallengeSender protocol).
283
-
284
- If `allowsInvalidSSLCertificate` is set to YES, `connection:willSendRequestForAuthenticationChallenge:` will attempt to have the challenge sender use credentials with invalid SSL certificates.
285
- */
286
- - (void)setWillSendRequestForAuthenticationChallengeBlock:(void (^)(NSURLConnection *connection, NSURLAuthenticationChallenge *challenge))block;
287
-
288
- /**
289
- Sets a block to be executed when the server redirects the request from one URL to another URL, or when the request URL changed by the `NSURLProtocol` subclass handling the request in order to standardize its format, as handled by the `NSURLConnectionDelegate` method `connection:willSendRequest:redirectResponse:`.
290
-
291
- @param block A block object to be executed when the request URL was changed. The block returns an `NSURLRequest` object, the URL request to redirect, and takes three arguments: the URL connection object, the the proposed redirected request, and the URL response that caused the redirect.
292
- */
293
- - (void)setRedirectResponseBlock:(NSURLRequest * (^)(NSURLConnection *connection, NSURLRequest *request, NSURLResponse *redirectResponse))block;
294
-
295
- /**
296
- Sets a block to be executed to modify the response a connection will cache, if any, as handled by the `NSURLConnectionDelegate` method `connection:willCacheResponse:`.
297
-
298
- @param block A block object to be executed to determine what response a connection will cache, if any. The block returns an `NSCachedURLResponse` object, the cached response to store in memory or `nil` to prevent the response from being cached, and takes two arguments: the URL connection object, and the cached response provided for the request.
299
- */
300
- - (void)setCacheResponseBlock:(NSCachedURLResponse * (^)(NSURLConnection *connection, NSCachedURLResponse *cachedResponse))block;
301
-
302
- @end
303
-
304
- ///----------------
305
- /// @name Constants
306
- ///----------------
307
-
308
- /**
309
- ## SSL Pinning Options
310
-
311
- The following constants are provided by `AFURLConnectionOperation` as possible SSL Pinning options.
312
-
313
- enum {
314
- AFSSLPinningModeNone,
315
- AFSSLPinningModePublicKey,
316
- AFSSLPinningModeCertificate,
317
- }
318
-
319
- `AFSSLPinningModeNone`
320
- Do not pin SSL connections
321
-
322
- `AFSSLPinningModePublicKey`
323
- Pin SSL connections to certificate public key (SPKI).
324
-
325
- `AFSSLPinningModeCertificate`
326
- Pin SSL connections to exact certificate. This may cause problems when your certificate expires and needs re-issuance.
327
-
328
- ## User info dictionary keys
329
-
330
- These keys may exist in the user info dictionary, in addition to those defined for NSError.
331
-
332
- - `NSString * const AFNetworkingOperationFailingURLRequestErrorKey`
333
- - `NSString * const AFNetworkingOperationFailingURLResponseErrorKey`
334
-
335
- ### Constants
336
-
337
- `AFNetworkingOperationFailingURLRequestErrorKey`
338
- The corresponding value is an `NSURLRequest` containing the request of the operation associated with an error. This key is only present in the `AFNetworkingErrorDomain`.
339
-
340
- `AFNetworkingOperationFailingURLResponseErrorKey`
341
- The corresponding value is an `NSURLResponse` containing the response of the operation associated with an error. This key is only present in the `AFNetworkingErrorDomain`.
342
-
343
- ## Error Domains
344
-
345
- The following error domain is predefined.
346
-
347
- - `NSString * const AFNetworkingErrorDomain`
348
-
349
- ### Constants
350
-
351
- `AFNetworkingErrorDomain`
352
- AFNetworking errors. Error codes for `AFNetworkingErrorDomain` correspond to codes in `NSURLErrorDomain`.
353
- */
354
- extern NSString * const AFNetworkingErrorDomain;
355
- extern NSString * const AFNetworkingOperationFailingURLRequestErrorKey;
356
- extern NSString * const AFNetworkingOperationFailingURLResponseErrorKey;
357
-
358
- ///--------------------
359
- /// @name Notifications
360
- ///--------------------
361
-
362
- /**
363
- Posted when an operation begins executing.
364
- */
365
- extern NSString * const AFNetworkingOperationDidStartNotification;
366
-
367
- /**
368
- Posted when an operation finishes.
369
- */
370
- extern NSString * const AFNetworkingOperationDidFinishNotification;
@@ -1,89 +0,0 @@
1
- // AFXMLRequestOperation.h
2
- //
3
- // Copyright (c) 2011 Gowalla (http://gowalla.com/)
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
13
- // all 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
21
- // THE SOFTWARE.
22
-
23
- #import <Foundation/Foundation.h>
24
- #import "AFHTTPRequestOperation.h"
25
-
26
- #import <Availability.h>
27
-
28
- /**
29
- `AFXMLRequestOperation` is a subclass of `AFHTTPRequestOperation` for downloading and working with XML response data.
30
-
31
- ## Acceptable Content Types
32
-
33
- By default, `AFXMLRequestOperation` accepts the following MIME types, which includes the official standard, `application/xml`, as well as other commonly-used types:
34
-
35
- - `application/xml`
36
- - `text/xml`
37
-
38
- ## Use With AFHTTPClient
39
-
40
- When `AFXMLRequestOperation` is registered with `AFHTTPClient`, the response object in the success callback of `HTTPRequestOperationWithRequest:success:failure:` will be an instance of `NSXMLParser`. On platforms that support `NSXMLDocument`, you have the option to ignore the response object, and simply use the `responseXMLDocument` property of the operation argument of the callback.
41
- */
42
- @interface AFXMLRequestOperation : AFHTTPRequestOperation
43
-
44
- ///----------------------------
45
- /// @name Getting Response Data
46
- ///----------------------------
47
-
48
- /**
49
- An `NSXMLParser` object constructed from the response data.
50
- */
51
- @property (readonly, nonatomic, strong) NSXMLParser *responseXMLParser;
52
-
53
- #ifdef __MAC_OS_X_VERSION_MIN_REQUIRED
54
- /**
55
- An `NSXMLDocument` object constructed from the response data. If an error occurs while parsing, `nil` will be returned, and the `error` property will be set to the error.
56
- */
57
- @property (readonly, nonatomic, strong) NSXMLDocument *responseXMLDocument;
58
- #endif
59
-
60
- /**
61
- Creates and returns an `AFXMLRequestOperation` object and sets the specified success and failure callbacks.
62
-
63
- @param urlRequest The request object to be loaded asynchronously during execution of the operation
64
- @param success A block object to be executed when the operation finishes successfully. This block has no return value and takes three arguments: the request sent from the client, the response received from the server, and the XML parser constructed with the response data of request.
65
- @param failure A block object to be executed when the operation finishes unsuccessfully. This block has no return value and takes three arguments: the request sent from the client, the response received from the server, and the error describing the network error that occurred.
66
-
67
- @return A new XML request operation
68
- */
69
- + (instancetype)XMLParserRequestOperationWithRequest:(NSURLRequest *)urlRequest
70
- success:(void (^)(NSURLRequest *request, NSHTTPURLResponse *response, NSXMLParser *XMLParser))success
71
- failure:(void (^)(NSURLRequest *request, NSHTTPURLResponse *response, NSError *error, NSXMLParser *XMLParser))failure;
72
-
73
-
74
- #ifdef __MAC_OS_X_VERSION_MIN_REQUIRED
75
- /**
76
- Creates and returns an `AFXMLRequestOperation` object and sets the specified success and failure callbacks.
77
-
78
- @param urlRequest The request object to be loaded asynchronously during execution of the operation
79
- @param success A block object to be executed when the operation finishes successfully. This block has no return value and takes three arguments: the request sent from the client, the response received from the server, and the XML document created from the response data of request.
80
- @param failure A block object to be executed when the operation finishes unsuccessfully, or that finishes successfully, but encountered an error while parsing the response data as XML. This block has no return value and takes three arguments: the request sent from the client, the response received from the server, and the error describing the network or parsing error that occurred.
81
-
82
- @return A new XML request operation
83
- */
84
- + (instancetype)XMLDocumentRequestOperationWithRequest:(NSURLRequest *)urlRequest
85
- success:(void (^)(NSURLRequest *request, NSHTTPURLResponse *response, NSXMLDocument *document))success
86
- failure:(void (^)(NSURLRequest *request, NSHTTPURLResponse *response, NSError *error, NSXMLDocument *document))failure;
87
- #endif
88
-
89
- @end