motion-yapper 0.0.3 → 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (294) hide show
  1. checksums.yaml +4 -4
  2. data/.gitignore +1 -0
  3. data/.travis.yml +3 -1
  4. data/lib/yapper.rb +3 -3
  5. data/lib/yapper/db.rb +61 -4
  6. data/lib/yapper/document/persistence.rb +4 -0
  7. data/lib/yapper/document/selection.rb +13 -0
  8. data/lib/yapper/version.rb +1 -1
  9. data/motion-yapper.gemspec +1 -1
  10. data/spec/integration/search_spec.rb +111 -0
  11. data/vendor/Podfile.lock +11 -7
  12. data/vendor/YapDatabaseRubyMotion/YapDatabaseRubyMotion.bridgesupport +16 -2
  13. data/vendor/YapDatabaseRubyMotion/YapDatabaseRubyMotion.h +10 -7
  14. data/vendor/YapDatabaseRubyMotion/YapDatabaseRubyMotion.m +20 -2
  15. metadata +19 -297
  16. data/vendor/Pods/.build/libPods-CocoaLumberjack.a +0 -0
  17. data/vendor/Pods/.build/libPods-NSData+MD5Digest.a +0 -0
  18. data/vendor/Pods/.build/libPods-YapDatabase.a +0 -0
  19. data/vendor/Pods/.build/libPods.a +0 -0
  20. data/vendor/Pods/BuildHeaders/CocoaLumberjack/DDASLLogger.h +0 -41
  21. data/vendor/Pods/BuildHeaders/CocoaLumberjack/DDAbstractDatabaseLogger.h +0 -102
  22. data/vendor/Pods/BuildHeaders/CocoaLumberjack/DDContextFilterLogFormatter.h +0 -63
  23. data/vendor/Pods/BuildHeaders/CocoaLumberjack/DDDispatchQueueLogFormatter.h +0 -128
  24. data/vendor/Pods/BuildHeaders/CocoaLumberjack/DDFileLogger.h +0 -369
  25. data/vendor/Pods/BuildHeaders/CocoaLumberjack/DDLog+LOGV.h +0 -99
  26. data/vendor/Pods/BuildHeaders/CocoaLumberjack/DDLog.h +0 -634
  27. data/vendor/Pods/BuildHeaders/CocoaLumberjack/DDMultiFormatter.h +0 -30
  28. data/vendor/Pods/BuildHeaders/CocoaLumberjack/DDTTYLogger.h +0 -181
  29. data/vendor/Pods/BuildHeaders/NSData+MD5Digest/NSData+MD5Digest.h +0 -18
  30. data/vendor/Pods/BuildHeaders/YapDatabase/NSDictionary+YapDatabase.h +0 -8
  31. data/vendor/Pods/BuildHeaders/YapDatabase/YapCache.h +0 -91
  32. data/vendor/Pods/BuildHeaders/YapDatabase/YapCollectionKey.h +0 -23
  33. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabase.h +0 -547
  34. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseConnection.h +0 -449
  35. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseConnectionState.h +0 -29
  36. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseDefaults.h +0 -37
  37. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseExtension.h +0 -15
  38. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseExtensionConnection.h +0 -11
  39. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseExtensionPrivate.h +0 -444
  40. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseExtensionTransaction.h +0 -11
  41. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseFilteredView.h +0 -81
  42. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseFilteredViewConnection.h +0 -12
  43. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseFilteredViewPrivate.h +0 -17
  44. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseFilteredViewTransaction.h +0 -39
  45. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseFilteredViewTypes.h +0 -32
  46. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseFullTextSearch.h +0 -89
  47. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseFullTextSearchConnection.h +0 -32
  48. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseFullTextSearchPrivate.h +0 -77
  49. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseFullTextSearchSnippetOptions.h +0 -79
  50. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseFullTextSearchTransaction.h +0 -68
  51. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseLogging.h +0 -158
  52. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseManager.h +0 -17
  53. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabasePrivate.h +0 -446
  54. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseQuery.h +0 -42
  55. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseRelationship.h +0 -35
  56. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseRelationshipConnection.h +0 -29
  57. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseRelationshipEdge.h +0 -163
  58. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseRelationshipEdgePrivate.h +0 -79
  59. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseRelationshipNode.h +0 -99
  60. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseRelationshipOptions.h +0 -59
  61. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseRelationshipPrivate.h +0 -125
  62. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseRelationshipTransaction.h +0 -384
  63. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseSecondaryIndex.h +0 -149
  64. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseSecondaryIndexConnection.h +0 -33
  65. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseSecondaryIndexPrivate.h +0 -83
  66. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseSecondaryIndexSetup.h +0 -33
  67. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseSecondaryIndexSetupPrivate.h +0 -18
  68. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseSecondaryIndexTransaction.h +0 -58
  69. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseStatement.h +0 -13
  70. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseString.h +0 -121
  71. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseTransaction.h +0 -651
  72. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseView.h +0 -127
  73. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseViewChange.h +0 -272
  74. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseViewChangePrivate.h +0 -94
  75. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseViewConnection.h +0 -116
  76. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseViewMappings.h +0 -842
  77. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseViewMappingsPrivate.h +0 -72
  78. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseViewOptions.h +0 -63
  79. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseViewPage.h +0 -36
  80. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseViewPageMetadata.h +0 -27
  81. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseViewPrivate.h +0 -170
  82. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseViewRangeOptions.h +0 -330
  83. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseViewRangeOptionsPrivate.h +0 -17
  84. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseViewTransaction.h +0 -498
  85. data/vendor/Pods/BuildHeaders/YapDatabase/YapDatabaseViewTypes.h +0 -99
  86. data/vendor/Pods/BuildHeaders/YapDatabase/YapMemoryTable.h +0 -74
  87. data/vendor/Pods/BuildHeaders/YapDatabase/YapNull.h +0 -17
  88. data/vendor/Pods/BuildHeaders/YapDatabase/YapSet.h +0 -41
  89. data/vendor/Pods/BuildHeaders/YapDatabase/YapTouch.h +0 -15
  90. data/vendor/Pods/CocoaLumberjack/LICENSE.txt +0 -18
  91. data/vendor/Pods/CocoaLumberjack/Lumberjack/DDASLLogger.h +0 -41
  92. data/vendor/Pods/CocoaLumberjack/Lumberjack/DDASLLogger.m +0 -100
  93. data/vendor/Pods/CocoaLumberjack/Lumberjack/DDAbstractDatabaseLogger.h +0 -102
  94. data/vendor/Pods/CocoaLumberjack/Lumberjack/DDAbstractDatabaseLogger.m +0 -727
  95. data/vendor/Pods/CocoaLumberjack/Lumberjack/DDFileLogger.h +0 -369
  96. data/vendor/Pods/CocoaLumberjack/Lumberjack/DDFileLogger.m +0 -1539
  97. data/vendor/Pods/CocoaLumberjack/Lumberjack/DDLog+LOGV.h +0 -99
  98. data/vendor/Pods/CocoaLumberjack/Lumberjack/DDLog.h +0 -634
  99. data/vendor/Pods/CocoaLumberjack/Lumberjack/DDLog.m +0 -1208
  100. data/vendor/Pods/CocoaLumberjack/Lumberjack/DDTTYLogger.h +0 -181
  101. data/vendor/Pods/CocoaLumberjack/Lumberjack/DDTTYLogger.m +0 -1520
  102. data/vendor/Pods/CocoaLumberjack/Lumberjack/Extensions/DDContextFilterLogFormatter.h +0 -63
  103. data/vendor/Pods/CocoaLumberjack/Lumberjack/Extensions/DDContextFilterLogFormatter.m +0 -191
  104. data/vendor/Pods/CocoaLumberjack/Lumberjack/Extensions/DDDispatchQueueLogFormatter.h +0 -128
  105. data/vendor/Pods/CocoaLumberjack/Lumberjack/Extensions/DDDispatchQueueLogFormatter.m +0 -253
  106. data/vendor/Pods/CocoaLumberjack/Lumberjack/Extensions/DDMultiFormatter.h +0 -30
  107. data/vendor/Pods/CocoaLumberjack/Lumberjack/Extensions/DDMultiFormatter.m +0 -127
  108. data/vendor/Pods/CocoaLumberjack/Lumberjack/Extensions/README.txt +0 -7
  109. data/vendor/Pods/CocoaLumberjack/README.markdown +0 -74
  110. data/vendor/Pods/Headers/CocoaLumberjack/DDASLLogger.h +0 -41
  111. data/vendor/Pods/Headers/CocoaLumberjack/DDAbstractDatabaseLogger.h +0 -102
  112. data/vendor/Pods/Headers/CocoaLumberjack/DDContextFilterLogFormatter.h +0 -63
  113. data/vendor/Pods/Headers/CocoaLumberjack/DDDispatchQueueLogFormatter.h +0 -128
  114. data/vendor/Pods/Headers/CocoaLumberjack/DDFileLogger.h +0 -369
  115. data/vendor/Pods/Headers/CocoaLumberjack/DDLog+LOGV.h +0 -99
  116. data/vendor/Pods/Headers/CocoaLumberjack/DDLog.h +0 -634
  117. data/vendor/Pods/Headers/CocoaLumberjack/DDMultiFormatter.h +0 -30
  118. data/vendor/Pods/Headers/CocoaLumberjack/DDTTYLogger.h +0 -181
  119. data/vendor/Pods/Headers/NSData+MD5Digest/NSData+MD5Digest.h +0 -18
  120. data/vendor/Pods/Headers/YapDatabase/YapCollectionKey.h +0 -23
  121. data/vendor/Pods/Headers/YapDatabase/YapDatabase.h +0 -547
  122. data/vendor/Pods/Headers/YapDatabase/YapDatabaseConnection.h +0 -449
  123. data/vendor/Pods/Headers/YapDatabase/YapDatabaseExtension.h +0 -15
  124. data/vendor/Pods/Headers/YapDatabase/YapDatabaseExtensionConnection.h +0 -11
  125. data/vendor/Pods/Headers/YapDatabase/YapDatabaseExtensionTransaction.h +0 -11
  126. data/vendor/Pods/Headers/YapDatabase/YapDatabaseFilteredView.h +0 -81
  127. data/vendor/Pods/Headers/YapDatabase/YapDatabaseFilteredViewConnection.h +0 -12
  128. data/vendor/Pods/Headers/YapDatabase/YapDatabaseFilteredViewTransaction.h +0 -39
  129. data/vendor/Pods/Headers/YapDatabase/YapDatabaseFilteredViewTypes.h +0 -32
  130. data/vendor/Pods/Headers/YapDatabase/YapDatabaseFullTextSearch.h +0 -89
  131. data/vendor/Pods/Headers/YapDatabase/YapDatabaseFullTextSearchConnection.h +0 -32
  132. data/vendor/Pods/Headers/YapDatabase/YapDatabaseFullTextSearchSnippetOptions.h +0 -79
  133. data/vendor/Pods/Headers/YapDatabase/YapDatabaseFullTextSearchTransaction.h +0 -68
  134. data/vendor/Pods/Headers/YapDatabase/YapDatabaseQuery.h +0 -42
  135. data/vendor/Pods/Headers/YapDatabase/YapDatabaseRelationship.h +0 -35
  136. data/vendor/Pods/Headers/YapDatabase/YapDatabaseRelationshipConnection.h +0 -29
  137. data/vendor/Pods/Headers/YapDatabase/YapDatabaseRelationshipEdge.h +0 -163
  138. data/vendor/Pods/Headers/YapDatabase/YapDatabaseRelationshipNode.h +0 -99
  139. data/vendor/Pods/Headers/YapDatabase/YapDatabaseRelationshipOptions.h +0 -59
  140. data/vendor/Pods/Headers/YapDatabase/YapDatabaseRelationshipTransaction.h +0 -384
  141. data/vendor/Pods/Headers/YapDatabase/YapDatabaseSecondaryIndex.h +0 -149
  142. data/vendor/Pods/Headers/YapDatabase/YapDatabaseSecondaryIndexConnection.h +0 -33
  143. data/vendor/Pods/Headers/YapDatabase/YapDatabaseSecondaryIndexSetup.h +0 -33
  144. data/vendor/Pods/Headers/YapDatabase/YapDatabaseSecondaryIndexTransaction.h +0 -58
  145. data/vendor/Pods/Headers/YapDatabase/YapDatabaseTransaction.h +0 -651
  146. data/vendor/Pods/Headers/YapDatabase/YapDatabaseView.h +0 -127
  147. data/vendor/Pods/Headers/YapDatabase/YapDatabaseViewChange.h +0 -272
  148. data/vendor/Pods/Headers/YapDatabase/YapDatabaseViewConnection.h +0 -116
  149. data/vendor/Pods/Headers/YapDatabase/YapDatabaseViewMappings.h +0 -842
  150. data/vendor/Pods/Headers/YapDatabase/YapDatabaseViewOptions.h +0 -63
  151. data/vendor/Pods/Headers/YapDatabase/YapDatabaseViewRangeOptions.h +0 -330
  152. data/vendor/Pods/Headers/YapDatabase/YapDatabaseViewTransaction.h +0 -498
  153. data/vendor/Pods/Headers/YapDatabase/YapDatabaseViewTypes.h +0 -99
  154. data/vendor/Pods/Headers/YapDatabase/YapSet.h +0 -41
  155. data/vendor/Pods/Headers/____Pods-CocoaLumberjack-prefix.h +0 -7
  156. data/vendor/Pods/Headers/____Pods-NSData+MD5Digest-prefix.h +0 -5
  157. data/vendor/Pods/Headers/____Pods-YapDatabase-prefix.h +0 -5
  158. data/vendor/Pods/Headers/____Pods-environment.h +0 -38
  159. data/vendor/Pods/Manifest.lock +0 -22
  160. data/vendor/Pods/NSData+MD5Digest/NSData+MD5Digest/NSData+MD5Digest.h +0 -18
  161. data/vendor/Pods/NSData+MD5Digest/NSData+MD5Digest/NSData+MD5Digest.m +0 -39
  162. data/vendor/Pods/NSData+MD5Digest/README.md +0 -11
  163. data/vendor/Pods/Pods-CocoaLumberjack-Private.xcconfig +0 -5
  164. data/vendor/Pods/Pods-CocoaLumberjack-dummy.m +0 -5
  165. data/vendor/Pods/Pods-CocoaLumberjack-prefix.pch +0 -7
  166. data/vendor/Pods/Pods-CocoaLumberjack.xcconfig +0 -0
  167. data/vendor/Pods/Pods-NSData+MD5Digest-Private.xcconfig +0 -5
  168. data/vendor/Pods/Pods-NSData+MD5Digest-dummy.m +0 -5
  169. data/vendor/Pods/Pods-NSData+MD5Digest-prefix.pch +0 -5
  170. data/vendor/Pods/Pods-NSData+MD5Digest.xcconfig +0 -0
  171. data/vendor/Pods/Pods-YapDatabase-Private.xcconfig +0 -5
  172. data/vendor/Pods/Pods-YapDatabase-dummy.m +0 -5
  173. data/vendor/Pods/Pods-YapDatabase-prefix.pch +0 -5
  174. data/vendor/Pods/Pods-YapDatabase.xcconfig +0 -1
  175. data/vendor/Pods/Pods-acknowledgements.markdown +0 -59
  176. data/vendor/Pods/Pods-acknowledgements.plist +0 -97
  177. data/vendor/Pods/Pods-dummy.m +0 -5
  178. data/vendor/Pods/Pods-environment.h +0 -38
  179. data/vendor/Pods/Pods-resources.sh +0 -68
  180. data/vendor/Pods/Pods.xcconfig +0 -5
  181. data/vendor/Pods/Pods.xcodeproj/project.pbxproj +0 -4807
  182. data/vendor/Pods/Pods.xcodeproj/xcuserdata/kareemk.xcuserdatad/xcschemes/Pods-CocoaLumberjack.xcscheme +0 -59
  183. data/vendor/Pods/Pods.xcodeproj/xcuserdata/kareemk.xcuserdatad/xcschemes/Pods-NSData+MD5Digest.xcscheme +0 -59
  184. data/vendor/Pods/Pods.xcodeproj/xcuserdata/kareemk.xcuserdatad/xcschemes/Pods-YapDatabase.xcscheme +0 -59
  185. data/vendor/Pods/Pods.xcodeproj/xcuserdata/kareemk.xcuserdatad/xcschemes/Pods.xcscheme +0 -59
  186. data/vendor/Pods/Pods.xcodeproj/xcuserdata/kareemk.xcuserdatad/xcschemes/xcschememanagement.plist +0 -31
  187. data/vendor/Pods/YapDatabase/LICENSE.txt +0 -18
  188. data/vendor/Pods/YapDatabase/README.md +0 -32
  189. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/FilteredViews/Internal/YapDatabaseFilteredViewPrivate.h +0 -17
  190. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/FilteredViews/YapDatabaseFilteredView.h +0 -81
  191. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/FilteredViews/YapDatabaseFilteredView.m +0 -159
  192. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/FilteredViews/YapDatabaseFilteredViewConnection.h +0 -12
  193. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/FilteredViews/YapDatabaseFilteredViewConnection.m +0 -41
  194. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/FilteredViews/YapDatabaseFilteredViewTransaction.h +0 -39
  195. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/FilteredViews/YapDatabaseFilteredViewTransaction.m +0 -1235
  196. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/FilteredViews/YapDatabaseFilteredViewTypes.h +0 -32
  197. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/FullTextSearch/Internal/YapDatabaseFullTextSearchPrivate.h +0 -77
  198. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/FullTextSearch/YapDatabaseFullTextSearch.h +0 -89
  199. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/FullTextSearch/YapDatabaseFullTextSearch.m +0 -146
  200. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/FullTextSearch/YapDatabaseFullTextSearchConnection.h +0 -32
  201. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/FullTextSearch/YapDatabaseFullTextSearchConnection.m +0 -298
  202. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/FullTextSearch/YapDatabaseFullTextSearchSnippetOptions.h +0 -79
  203. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/FullTextSearch/YapDatabaseFullTextSearchSnippetOptions.m +0 -95
  204. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/FullTextSearch/YapDatabaseFullTextSearchTransaction.h +0 -68
  205. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/FullTextSearch/YapDatabaseFullTextSearchTransaction.m +0 -1403
  206. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Protocol/Internal/YapDatabaseExtensionPrivate.h +0 -444
  207. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Protocol/YapDatabaseExtension.h +0 -15
  208. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Protocol/YapDatabaseExtension.m +0 -83
  209. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Protocol/YapDatabaseExtensionConnection.h +0 -11
  210. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Protocol/YapDatabaseExtensionConnection.m +0 -46
  211. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Protocol/YapDatabaseExtensionTransaction.h +0 -11
  212. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Protocol/YapDatabaseExtensionTransaction.m +0 -204
  213. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Relationships/Internal/YapDatabaseRelationshipEdgePrivate.h +0 -79
  214. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Relationships/Internal/YapDatabaseRelationshipPrivate.h +0 -125
  215. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Relationships/YapDatabaseRelationship.h +0 -35
  216. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Relationships/YapDatabaseRelationship.m +0 -129
  217. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Relationships/YapDatabaseRelationshipConnection.h +0 -29
  218. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Relationships/YapDatabaseRelationshipConnection.m +0 -802
  219. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Relationships/YapDatabaseRelationshipEdge.h +0 -163
  220. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Relationships/YapDatabaseRelationshipEdge.m +0 -408
  221. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Relationships/YapDatabaseRelationshipNode.h +0 -99
  222. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Relationships/YapDatabaseRelationshipOptions.h +0 -59
  223. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Relationships/YapDatabaseRelationshipOptions.m +0 -29
  224. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Relationships/YapDatabaseRelationshipTransaction.h +0 -384
  225. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Relationships/YapDatabaseRelationshipTransaction.m +0 -5254
  226. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/SecondaryIndex/Internal/YapDatabaseSecondaryIndexPrivate.h +0 -83
  227. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/SecondaryIndex/Internal/YapDatabaseSecondaryIndexSetupPrivate.h +0 -18
  228. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/SecondaryIndex/YapDatabaseSecondaryIndex.h +0 -149
  229. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/SecondaryIndex/YapDatabaseSecondaryIndex.m +0 -161
  230. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/SecondaryIndex/YapDatabaseSecondaryIndexConnection.h +0 -33
  231. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/SecondaryIndex/YapDatabaseSecondaryIndexConnection.m +0 -331
  232. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/SecondaryIndex/YapDatabaseSecondaryIndexSetup.h +0 -33
  233. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/SecondaryIndex/YapDatabaseSecondaryIndexSetup.m +0 -245
  234. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/SecondaryIndex/YapDatabaseSecondaryIndexTransaction.h +0 -58
  235. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/SecondaryIndex/YapDatabaseSecondaryIndexTransaction.m +0 -1269
  236. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Views/Internal/YapDatabaseViewChangePrivate.h +0 -94
  237. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Views/Internal/YapDatabaseViewMappingsPrivate.h +0 -72
  238. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Views/Internal/YapDatabaseViewPage.h +0 -36
  239. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Views/Internal/YapDatabaseViewPage.mm +0 -296
  240. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Views/Internal/YapDatabaseViewPageMetadata.h +0 -27
  241. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Views/Internal/YapDatabaseViewPageMetadata.m +0 -28
  242. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Views/Internal/YapDatabaseViewPrivate.h +0 -170
  243. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Views/Internal/YapDatabaseViewRangeOptionsPrivate.h +0 -17
  244. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Views/Utilities/YapDatabaseViewChange.h +0 -272
  245. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Views/Utilities/YapDatabaseViewChange.m +0 -2500
  246. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Views/Utilities/YapDatabaseViewMappings.h +0 -842
  247. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Views/Utilities/YapDatabaseViewMappings.m +0 -1714
  248. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Views/Utilities/YapDatabaseViewRangeOptions.h +0 -330
  249. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Views/Utilities/YapDatabaseViewRangeOptions.m +0 -141
  250. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Views/YapDatabaseView.h +0 -127
  251. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Views/YapDatabaseView.m +0 -194
  252. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Views/YapDatabaseViewConnection.h +0 -116
  253. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Views/YapDatabaseViewConnection.m +0 -888
  254. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Views/YapDatabaseViewOptions.h +0 -63
  255. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Views/YapDatabaseViewOptions.m +0 -27
  256. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Views/YapDatabaseViewTransaction.h +0 -498
  257. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Views/YapDatabaseViewTransaction.m +0 -4986
  258. data/vendor/Pods/YapDatabase/YapDatabase/Extensions/Views/YapDatabaseViewTypes.h +0 -99
  259. data/vendor/Pods/YapDatabase/YapDatabase/Internal/NSDictionary+YapDatabase.h +0 -8
  260. data/vendor/Pods/YapDatabase/YapDatabase/Internal/NSDictionary+YapDatabase.m +0 -19
  261. data/vendor/Pods/YapDatabase/YapDatabase/Internal/YapCache.h +0 -91
  262. data/vendor/Pods/YapDatabase/YapDatabase/Internal/YapCache.m +0 -465
  263. data/vendor/Pods/YapDatabase/YapDatabase/Internal/YapDatabaseConnectionState.h +0 -29
  264. data/vendor/Pods/YapDatabase/YapDatabase/Internal/YapDatabaseConnectionState.m +0 -48
  265. data/vendor/Pods/YapDatabase/YapDatabase/Internal/YapDatabaseDefaults.h +0 -37
  266. data/vendor/Pods/YapDatabase/YapDatabase/Internal/YapDatabaseDefaults.m +0 -83
  267. data/vendor/Pods/YapDatabase/YapDatabase/Internal/YapDatabaseLogging.h +0 -158
  268. data/vendor/Pods/YapDatabase/YapDatabase/Internal/YapDatabaseLogging.m +0 -73
  269. data/vendor/Pods/YapDatabase/YapDatabase/Internal/YapDatabaseManager.h +0 -17
  270. data/vendor/Pods/YapDatabase/YapDatabase/Internal/YapDatabaseManager.m +0 -56
  271. data/vendor/Pods/YapDatabase/YapDatabase/Internal/YapDatabasePrivate.h +0 -446
  272. data/vendor/Pods/YapDatabase/YapDatabase/Internal/YapDatabaseStatement.h +0 -13
  273. data/vendor/Pods/YapDatabase/YapDatabase/Internal/YapDatabaseStatement.m +0 -26
  274. data/vendor/Pods/YapDatabase/YapDatabase/Internal/YapDatabaseString.h +0 -121
  275. data/vendor/Pods/YapDatabase/YapDatabase/Internal/YapMemoryTable.h +0 -74
  276. data/vendor/Pods/YapDatabase/YapDatabase/Internal/YapMemoryTable.m +0 -603
  277. data/vendor/Pods/YapDatabase/YapDatabase/Internal/YapNull.h +0 -17
  278. data/vendor/Pods/YapDatabase/YapDatabase/Internal/YapNull.m +0 -35
  279. data/vendor/Pods/YapDatabase/YapDatabase/Internal/YapTouch.h +0 -15
  280. data/vendor/Pods/YapDatabase/YapDatabase/Internal/YapTouch.m +0 -31
  281. data/vendor/Pods/YapDatabase/YapDatabase/Utilities/YapCollectionKey.h +0 -23
  282. data/vendor/Pods/YapDatabase/YapDatabase/Utilities/YapCollectionKey.m +0 -199
  283. data/vendor/Pods/YapDatabase/YapDatabase/Utilities/YapDatabaseQuery.h +0 -42
  284. data/vendor/Pods/YapDatabase/YapDatabase/Utilities/YapDatabaseQuery.m +0 -96
  285. data/vendor/Pods/YapDatabase/YapDatabase/Utilities/YapSet.h +0 -41
  286. data/vendor/Pods/YapDatabase/YapDatabase/Utilities/YapSet.m +0 -82
  287. data/vendor/Pods/YapDatabase/YapDatabase/YapDatabase.h +0 -547
  288. data/vendor/Pods/YapDatabase/YapDatabase/YapDatabase.m +0 -2013
  289. data/vendor/Pods/YapDatabase/YapDatabase/YapDatabaseConnection.h +0 -449
  290. data/vendor/Pods/YapDatabase/YapDatabase/YapDatabaseConnection.m +0 -4046
  291. data/vendor/Pods/YapDatabase/YapDatabase/YapDatabaseTransaction.h +0 -651
  292. data/vendor/Pods/YapDatabase/YapDatabase/YapDatabaseTransaction.m +0 -5602
  293. data/vendor/Pods/build-iPhoneSimulator/Pods.bridgesupport +0 -3172
  294. data/vendor/Pods/build-iPhoneSimulator/libPods.a +0 -0
@@ -1,30 +0,0 @@
1
- #import <Foundation/Foundation.h>
2
- #import "DDLog.h"
3
-
4
- /**
5
- * Welcome to Cocoa Lumberjack!
6
- *
7
- * The project page has a wealth of documentation if you have any questions.
8
- * https://github.com/CocoaLumberjack/CocoaLumberjack
9
- *
10
- * If you're new to the project you may wish to read the "Getting Started" page.
11
- * https://github.com/CocoaLumberjack/CocoaLumberjack/wiki/GettingStarted
12
- *
13
- *
14
- * This formatter can be used to chain different formatters together.
15
- * The log message will processed in the order of the formatters added.
16
- **/
17
-
18
- @interface DDMultiFormatter : NSObject <DDLogFormatter>
19
-
20
- /**
21
- * Array of chained formatters
22
- */
23
- @property (readonly) NSArray *formatters;
24
-
25
- - (void)addFormatter:(id<DDLogFormatter>)formatter;
26
- - (void)removeFormatter:(id<DDLogFormatter>)formatter;
27
- - (void)removeAllFormatters;
28
- - (BOOL)isFormattingWithFormatter:(id<DDLogFormatter>)formatter;
29
-
30
- @end
@@ -1,181 +0,0 @@
1
- #import <Foundation/Foundation.h>
2
- #if TARGET_OS_IPHONE
3
- #import <UIKit/UIColor.h> // iOS
4
- #elif !defined (COCOAPODS_POD_AVAILABLE_CocoaLumberjack_CLI)
5
- #import <AppKit/NSColor.h> // OS X with AppKit
6
- #else
7
- #import "CLIColor.h" // OS X without AppKit
8
- #endif
9
-
10
- #import "DDLog.h"
11
-
12
- #define LOG_CONTEXT_ALL INT_MAX
13
-
14
- /**
15
- * Welcome to Cocoa Lumberjack!
16
- *
17
- * The project page has a wealth of documentation if you have any questions.
18
- * https://github.com/CocoaLumberjack/CocoaLumberjack
19
- *
20
- * If you're new to the project you may wish to read the "Getting Started" wiki.
21
- * https://github.com/CocoaLumberjack/CocoaLumberjack/wiki/GettingStarted
22
- *
23
- *
24
- * This class provides a logger for Terminal output or Xcode console output,
25
- * depending on where you are running your code.
26
- *
27
- * As described in the "Getting Started" page,
28
- * the traditional NSLog() function directs it's output to two places:
29
- *
30
- * - Apple System Log (so it shows up in Console.app)
31
- * - StdErr (if stderr is a TTY, so log statements show up in Xcode console)
32
- *
33
- * To duplicate NSLog() functionality you can simply add this logger and an asl logger.
34
- * However, if you instead choose to use file logging (for faster performance),
35
- * you may choose to use only a file logger and a tty logger.
36
- **/
37
-
38
- @interface DDTTYLogger : DDAbstractLogger <DDLogger>
39
- {
40
- NSCalendar *calendar;
41
- NSUInteger calendarUnitFlags;
42
-
43
- NSString *appName;
44
- char *app;
45
- size_t appLen;
46
-
47
- NSString *processID;
48
- char *pid;
49
- size_t pidLen;
50
-
51
- BOOL colorsEnabled;
52
- NSMutableArray *colorProfilesArray;
53
- NSMutableDictionary *colorProfilesDict;
54
- }
55
-
56
- + (instancetype)sharedInstance;
57
-
58
- /* Inherited from the DDLogger protocol:
59
- *
60
- * Formatters may optionally be added to any logger.
61
- *
62
- * If no formatter is set, the logger simply logs the message as it is given in logMessage,
63
- * or it may use its own built in formatting style.
64
- *
65
- * More information about formatters can be found here:
66
- * https://github.com/CocoaLumberjack/CocoaLumberjack/wiki/CustomFormatters
67
- *
68
- * The actual implementation of these methods is inherited from DDAbstractLogger.
69
-
70
- - (id <DDLogFormatter>)logFormatter;
71
- - (void)setLogFormatter:(id <DDLogFormatter>)formatter;
72
-
73
- */
74
-
75
- /**
76
- * Want to use different colors for different log levels?
77
- * Enable this property.
78
- *
79
- * If you run the application via the Terminal (not Xcode),
80
- * the logger will map colors to xterm-256color or xterm-color (if available).
81
- *
82
- * Xcode does NOT natively support colors in the Xcode debugging console.
83
- * You'll need to install the XcodeColors plugin to see colors in the Xcode console.
84
- * https://github.com/robbiehanson/XcodeColors
85
- *
86
- * The default value if NO.
87
- **/
88
- @property (readwrite, assign) BOOL colorsEnabled;
89
-
90
- /**
91
- * The default color set (foregroundColor, backgroundColor) is:
92
- *
93
- * - LOG_FLAG_ERROR = (red, nil)
94
- * - LOG_FLAG_WARN = (orange, nil)
95
- *
96
- * You can customize the colors however you see fit.
97
- * Please note that you are passing a flag, NOT a level.
98
- *
99
- * GOOD : [ttyLogger setForegroundColor:pink backgroundColor:nil forFlag:LOG_FLAG_INFO]; // <- Good :)
100
- * BAD : [ttyLogger setForegroundColor:pink backgroundColor:nil forFlag:LOG_LEVEL_INFO]; // <- BAD! :(
101
- *
102
- * LOG_FLAG_INFO = 0...00100
103
- * LOG_LEVEL_INFO = 0...00111 <- Would match LOG_FLAG_INFO and LOG_FLAG_WARN and LOG_FLAG_ERROR
104
- *
105
- * If you run the application within Xcode, then the XcodeColors plugin is required.
106
- *
107
- * If you run the application from a shell, then DDTTYLogger will automatically map the given color to
108
- * the closest available color. (xterm-256color or xterm-color which have 256 and 16 supported colors respectively.)
109
- *
110
- * This method invokes setForegroundColor:backgroundColor:forFlag:context: and applies it to `LOG_CONTEXT_ALL`.
111
- **/
112
- #if TARGET_OS_IPHONE
113
- - (void)setForegroundColor:(UIColor *)txtColor backgroundColor:(UIColor *)bgColor forFlag:(int)mask;
114
- #elif !defined (COCOAPODS_POD_AVAILABLE_CocoaLumberjack_CLI)
115
- - (void)setForegroundColor:(NSColor *)txtColor backgroundColor:(NSColor *)bgColor forFlag:(int)mask;
116
- #else
117
- - (void)setForegroundColor:(CLIColor *)txtColor backgroundColor:(CLIColor *)bgColor forFlag:(int)mask;
118
- #endif
119
-
120
- /**
121
- * Just like setForegroundColor:backgroundColor:flag, but allows you to specify a particular logging context.
122
- *
123
- * A logging context is often used to identify log messages coming from a 3rd party framework,
124
- * although logging context's can be used for many different functions.
125
- *
126
- * Use LOG_CONTEXT_ALL to set the deafult color for all contexts that have no specific color set defined.
127
- *
128
- * Logging context's are explained in further detail here:
129
- * https://github.com/CocoaLumberjack/CocoaLumberjack/wiki/CustomContext
130
- **/
131
- #if TARGET_OS_IPHONE
132
- - (void)setForegroundColor:(UIColor *)txtColor backgroundColor:(UIColor *)bgColor forFlag:(int)mask context:(int)ctxt;
133
- #elif !defined (COCOAPODS_POD_AVAILABLE_CocoaLumberjack_CLI)
134
- - (void)setForegroundColor:(NSColor *)txtColor backgroundColor:(NSColor *)bgColor forFlag:(int)mask context:(int)ctxt;
135
- #else
136
- - (void)setForegroundColor:(CLIColor *)txtColor backgroundColor:(CLIColor *)bgColor forFlag:(int)mask context:(int)ctxt;
137
- #endif
138
-
139
- /**
140
- * Similar to the methods above, but allows you to map DDLogMessage->tag to a particular color profile.
141
- * For example, you could do something like this:
142
- *
143
- * static NSString *const PurpleTag = @"PurpleTag";
144
- *
145
- * #define DDLogPurple(frmt, ...) LOG_OBJC_TAG_MACRO(NO, 0, 0, 0, PurpleTag, frmt, ##__VA_ARGS__)
146
- *
147
- * And then in your applicationDidFinishLaunching, or wherever you configure Lumberjack:
148
- *
149
- * #if TARGET_OS_IPHONE
150
- * UIColor *purple = [UIColor colorWithRed:(64/255.0) green:(0/255.0) blue:(128/255.0) alpha:1.0];
151
- * #else
152
- * NSColor *purple = [NSColor colorWithCalibratedRed:(64/255.0) green:(0/255.0) blue:(128/255.0) alpha:1.0];
153
- *
154
- * Note: For CLI OS X projects that don't link with AppKit use CLIColor objects instead
155
- *
156
- * [[DDTTYLogger sharedInstance] setForegroundColor:purple backgroundColor:nil forTag:PurpleTag];
157
- * [DDLog addLogger:[DDTTYLogger sharedInstance]];
158
- *
159
- * This would essentially give you a straight NSLog replacement that prints in purple:
160
- *
161
- * DDLogPurple(@"I'm a purple log message!");
162
- **/
163
- #if TARGET_OS_IPHONE
164
- - (void)setForegroundColor:(UIColor *)txtColor backgroundColor:(UIColor *)bgColor forTag:(id <NSCopying>)tag;
165
- #elif !defined (COCOAPODS_POD_AVAILABLE_CocoaLumberjack_CLI)
166
- - (void)setForegroundColor:(NSColor *)txtColor backgroundColor:(NSColor *)bgColor forTag:(id <NSCopying>)tag;
167
- #else
168
- - (void)setForegroundColor:(CLIColor *)txtColor backgroundColor:(CLIColor *)bgColor forTag:(id <NSCopying>)tag;
169
- #endif
170
-
171
- /**
172
- * Clearing color profiles.
173
- **/
174
- - (void)clearColorsForFlag:(int)mask;
175
- - (void)clearColorsForFlag:(int)mask context:(int)context;
176
- - (void)clearColorsForTag:(id <NSCopying>)tag;
177
- - (void)clearColorsForAllFlags;
178
- - (void)clearColorsForAllTags;
179
- - (void)clearAllColors;
180
-
181
- @end
@@ -1,18 +0,0 @@
1
- //
2
- // NSData+MD5Digest.h
3
- // NSData+MD5Digest
4
- //
5
- // Created by Francis Chong on 12年6月5日.
6
- //
7
-
8
- #import <Foundation/Foundation.h>
9
-
10
- @interface NSData (MD5Digest)
11
-
12
- +(NSData *)MD5Digest:(NSData *)input;
13
- -(NSData *)MD5Digest;
14
-
15
- +(NSString *)MD5HexDigest:(NSData *)input;
16
- -(NSString *)MD5HexDigest;
17
-
18
- @end
@@ -1,8 +0,0 @@
1
- #import <Foundation/Foundation.h>
2
-
3
-
4
- @interface NSDictionary (YapDatabase)
5
-
6
- - (BOOL)ydb_containsKey:(id)key;
7
-
8
- @end
@@ -1,91 +0,0 @@
1
- #import <Foundation/Foundation.h>
2
-
3
- #define YAP_CACHE_STATISTICS 0
4
-
5
- /**
6
- * YapCache implements a simple strict cache.
7
- *
8
- * It is very similar to NSCache and shares a similar API.
9
- * However, YapCache implements a strict countLimit and monitors usage so eviction is properly ordered.
10
- *
11
- * For example:
12
- * If you set a countLimit of 4, then when you add the 5th item to the cache, another item is automatically evicted.
13
- * It doesn't happen at a later time as with NSCache. It happens atomically during the addition of the 5th item.
14
-
15
- * Which item gets evicted? That depends entirely on usage.
16
- * YapCache maintains a doubly linked-list of keys ordered by access.
17
- * The most recently accessed key is at the front of the linked-list,
18
- * and the least recently accessed key is at the back.
19
- * So it's very quick and efficient to evict items based on recent usage.
20
- *
21
- * YapCache is NOT thread-safe.
22
- * It is designed to be used by the various YapDatabase classes, which inherently serialize access to the cache.
23
- **/
24
-
25
- @interface YapCache : NSObject
26
-
27
- /**
28
- * Initializes a cache.
29
- *
30
- * Since the countLimit is a common configuration, it may optionally be passed during initialization.
31
- * This is also used as a hint internally when initializing components (i.e. [NSMutableDictionary initWithCapacity:]).
32
- **/
33
- - (id)initWithKeyClass:(Class)keyClass;
34
- - (id)initWithKeyClass:(Class)keyClass countLimit:(NSUInteger)countLimit;
35
-
36
- /**
37
- * The countLimit specifies the maximum number of items to keep in the cache.
38
- * This limit is strictly enforced.
39
- *
40
- * The default countLimit is 40.
41
- *
42
- * You may optionally disable the countLimit by setting it to zero.
43
- *
44
- * You may change the countLimit at any time.
45
- * Changes to the countLimit take immediate effect on the cache (before the set method returns).
46
- * Thus, if needed, you can temporarily increase the cache size for certain operations.
47
- **/
48
- @property (nonatomic, assign, readwrite) NSUInteger countLimit;
49
-
50
- //
51
- // The normal cache stuff...
52
- //
53
-
54
- - (void)setObject:(id)object forKey:(id)key;
55
-
56
- - (id)objectForKey:(id)key;
57
- - (BOOL)containsKey:(id)key;
58
-
59
- - (NSUInteger)count;
60
-
61
- - (void)removeAllObjects;
62
- - (void)removeObjectForKey:(id)key;
63
- - (void)removeObjectsForKeys:(NSArray *)keys;
64
-
65
- - (void)enumerateKeysWithBlock:(void (^)(id key, BOOL *stop))block;
66
- - (void)enumerateKeysAndObjectsWithBlock:(void (^)(id key, id obj, BOOL *stop))block;
67
-
68
- //
69
- // Some debugging stuff that gets compiled out
70
- //
71
-
72
- #if YAP_CACHE_STATISTICS
73
-
74
- /**
75
- * When querying the cache for an object via objectForKey,
76
- * the hitCount is incremented if the object is in the cache,
77
- * and the missCount is incremented if the object is not in the cache.
78
- **/
79
- @property (nonatomic, readonly) NSUInteger hitCount;
80
- @property (nonatomic, readonly) NSUInteger missCount;
81
-
82
- /**
83
- * When adding objects to the cache via setObject:forKey:,
84
- * the evictionCount is incremented if the cache is full,
85
- * and the added object causes another object (the least recently used object) to be evicted.
86
- **/
87
- @property (nonatomic, readonly) NSUInteger evictionCount;
88
-
89
- #endif
90
-
91
- @end
@@ -1,23 +0,0 @@
1
- #import <Foundation/Foundation.h>
2
-
3
-
4
- /**
5
- * An efficient collection/key tuple class.
6
- *
7
- * Combines collection & key into a single object,
8
- * and provides the proper methods to use the object in various classes (such as NSDictionary, NSSet, etc).
9
- **/
10
- @interface YapCollectionKey : NSObject <NSCopying, NSCoding>
11
-
12
- - (id)initWithCollection:(NSString *)collection key:(NSString *)key;
13
-
14
- @property (nonatomic, strong, readonly) NSString *collection;
15
- @property (nonatomic, strong, readonly) NSString *key;
16
-
17
- - (BOOL)isEqualToCollectionKey:(YapCollectionKey *)collectionKey;
18
-
19
- // These methods are overriden and optimized:
20
- - (BOOL)isEqual:(id)anObject;
21
- - (NSUInteger)hash;
22
-
23
- @end
@@ -1,547 +0,0 @@
1
- #import <Foundation/Foundation.h>
2
-
3
- #import "YapDatabaseConnection.h"
4
- #import "YapDatabaseTransaction.h"
5
- #import "YapDatabaseExtension.h"
6
-
7
- /**
8
- * Welcome to YapDatabase!
9
- *
10
- * The project page has a wealth of documentation if you have any questions.
11
- * https://github.com/yaptv/YapDatabase
12
- *
13
- * If you're new to the project you may want to visit the wiki.
14
- * https://github.com/yaptv/YapDatabase/wiki
15
- *
16
- * The YapDatabase class is the top level class used to initialize the database.
17
- * It largely represents the immutable aspects of the database such as:
18
- *
19
- * - the filepath of the sqlite file
20
- * - the serializer and deserializer (for turning objects into data blobs, and back into objects again)
21
- *
22
- * To access or modify the database you create one or more connections to it.
23
- * Connections are thread-safe, and you can spawn multiple connections in order to achieve
24
- * concurrent access to the database from multiple threads.
25
- * You can even read from the database while writing to it from another connection on another thread.
26
- **/
27
-
28
- /**
29
- * How does YapDatabase store my objects to disk?
30
- *
31
- * That question is answered extensively in the wiki article "Storing Objects":
32
- * https://github.com/yaptv/YapDatabase/wiki/Storing-Objects
33
- *
34
- * Here's the intro from the wiki article:
35
- *
36
- * > In order to store an object to disk (via YapDatabase or any other protocol) you need some way of
37
- * > serializing the object. That is, convert the object into a big blob of bytes. And then, to get your
38
- * > object back from the disk you deserialize it (convert big blob of bytes back into object form).
39
- * >
40
- * > With YapDatabase, you can choose the default serialization/deserialization process,
41
- * > or you can customize it and use your own routines.
42
- *
43
- * In order to support adding objects to the database, serializers and deserializers are used.
44
- * The serializer and deserializer are just simple blocks that you can optionally configure.
45
- * The default serializer/deserializer uses NSCoding, so they are as simple and fast:
46
- *
47
- * defaultSerializer = ^(NSString *collection, NSString *key, id object){
48
- * return [NSKeyedArchiver archivedDataWithRootObject:object];
49
- * };
50
- * defaultDeserializer = ^(NSString *collection, NSString *key, NSData *data) {
51
- * return [NSKeyedUnarchiver unarchiveObjectWithData:data];
52
- * };
53
- *
54
- * If you use the initWithPath initializer, the default serializer/deserializer are used.
55
- * Thus to store objects in the database, the objects need only support the NSCoding protocol.
56
- * You may optionally use a custom serializer/deserializer for the objects and/or metadata.
57
- **/
58
- typedef NSData* (^YapDatabaseSerializer)(NSString *collection, NSString *key, id object);
59
- typedef id (^YapDatabaseDeserializer)(NSString *collection, NSString *key, NSData *data);
60
-
61
- /**
62
- * Is it safe to store mutable objects in the database?
63
- *
64
- * That question is answered extensively in the wiki article "Thread Safety":
65
- * https://github.com/yaptv/YapDatabase/wiki/Thread-Safety
66
- *
67
- * The sanitizer block can be run on all objects as they are being input into the database.
68
- * That is, it will be run on all objects passed to setObject:forKey:inCollection: before
69
- * being handed to the database internals.
70
- **/
71
- typedef id (^YapDatabaseSanitizer)(NSString *collection, NSString *key, id object);
72
-
73
-
74
- /**
75
- * This notification is posted following a readwrite transaction where the database was modified.
76
- *
77
- * It is documented in more detail in the wiki article "YapDatabaseModifiedNotification":
78
- * https://github.com/yaptv/YapDatabase/wiki/YapDatabaseModifiedNotification
79
- *
80
- * The notification object will be the database instance itself.
81
- * That is, it will be an instance of YapDatabase.
82
- *
83
- * The userInfo dictionary will look something like this:
84
- * @{
85
- * YapDatabaseSnapshotKey = <NSNumber of snapshot, incremented per read-write transaction w/modification>,
86
- * YapDatabaseConnectionKey = <YapDatabaseConnection instance that made the modification(s)>,
87
- * YapDatabaseExtensionsKey = <NSDictionary with individual changeset info per extension>,
88
- * YapDatabaseCustomKey = <Optional object associated with this change, set by you>,
89
- * }
90
- *
91
- * This notification is always posted to the main thread.
92
- **/
93
- extern NSString *const YapDatabaseModifiedNotification;
94
-
95
- extern NSString *const YapDatabaseSnapshotKey;
96
- extern NSString *const YapDatabaseConnectionKey;
97
- extern NSString *const YapDatabaseExtensionsKey;
98
- extern NSString *const YapDatabaseCustomKey;
99
-
100
- extern NSString *const YapDatabaseObjectChangesKey;
101
- extern NSString *const YapDatabaseMetadataChangesKey;
102
- extern NSString *const YapDatabaseRemovedKeysKey;
103
- extern NSString *const YapDatabaseRemovedCollectionsKey;
104
- extern NSString *const YapDatabaseAllKeysRemovedKey;
105
-
106
-
107
- @interface YapDatabase : NSObject
108
-
109
- /**
110
- * The default serializer & deserializer use NSCoding (NSKeyedArchiver & NSKeyedUnarchiver).
111
- * Thus any objects that support the NSCoding protocol may be used.
112
- *
113
- * Many of Apple's primary data types support NSCoding out of the box.
114
- * It's easy to add NSCoding support to your own custom objects.
115
- **/
116
- + (YapDatabaseSerializer)defaultSerializer;
117
- + (YapDatabaseDeserializer)defaultDeserializer;
118
-
119
- /**
120
- * Property lists ONLY support the following: NSData, NSString, NSArray, NSDictionary, NSDate, and NSNumber.
121
- * Property lists are highly optimized and are used extensively by Apple.
122
- *
123
- * Property lists make a good fit when your existing code already uses them,
124
- * such as replacing NSUserDefaults with a database.
125
- **/
126
- + (YapDatabaseSerializer)propertyListSerializer;
127
- + (YapDatabaseDeserializer)propertyListDeserializer;
128
-
129
- /**
130
- * A FASTER serializer & deserializer than the default, if serializing ONLY a NSDate object.
131
- * You may want to use timestampSerializer & timestampDeserializer if your metadata is simply an NSDate.
132
- **/
133
- + (YapDatabaseSerializer)timestampSerializer;
134
- + (YapDatabaseDeserializer)timestampDeserializer;
135
-
136
- ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
137
- #pragma mark Init
138
- ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
139
-
140
- /**
141
- * Opens or creates a sqlite database with the given path.
142
- * The default serializer and deserializer are used.
143
- * No sanitizer is used.
144
- *
145
- * @see defaultSerializer
146
- * @see defaultDeserializer
147
- **/
148
- - (id)initWithPath:(NSString *)path;
149
-
150
- /**
151
- * Opens or creates a sqlite database with the given path.
152
- * The given serializer and deserializer are used for both objects and metadata.
153
- * No sanitizer is used.
154
- **/
155
- - (id)initWithPath:(NSString *)path
156
- serializer:(YapDatabaseSerializer)serializer
157
- deserializer:(YapDatabaseDeserializer)deserializer;
158
-
159
- /**
160
- * Opens or creates a sqlite database with the given path.
161
- * The given serializer and deserializer are used for both objects and metadata.
162
- * The given sanitizer is used for both objects and metadata.
163
- **/
164
- - (id)initWithPath:(NSString *)path
165
- serializer:(YapDatabaseSerializer)serializer
166
- deserializer:(YapDatabaseDeserializer)deserializer
167
- sanitizer:(YapDatabaseSanitizer)sanitizer;
168
-
169
- /**
170
- * Opens or creates a sqlite database with the given path.
171
- * The given serializers and deserializers are used.
172
- * No sanitizer is used.
173
- **/
174
- - (id)initWithPath:(NSString *)path objectSerializer:(YapDatabaseSerializer)objectSerializer
175
- objectDeserializer:(YapDatabaseDeserializer)objectDeserializer
176
- metadataSerializer:(YapDatabaseSerializer)metadataSerializer
177
- metadataDeserializer:(YapDatabaseDeserializer)metadataDeserializer;
178
-
179
- /**
180
- * Opens or creates a sqlite database with the given path.
181
- * The given serializers and deserializers are used.
182
- * The given sanitizers are used.
183
- **/
184
- - (id)initWithPath:(NSString *)path objectSerializer:(YapDatabaseSerializer)objectSerializer
185
- objectDeserializer:(YapDatabaseDeserializer)objectDeserializer
186
- metadataSerializer:(YapDatabaseSerializer)metadataSerializer
187
- metadataDeserializer:(YapDatabaseDeserializer)metadataDeserializer
188
- objectSanitizer:(YapDatabaseSanitizer)objectSanitizer
189
- metadataSanitizer:(YapDatabaseSanitizer)metadataSanitizer;
190
-
191
- ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
192
- #pragma mark Properties
193
- ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
194
-
195
- @property (nonatomic, strong, readonly) NSString *databasePath;
196
-
197
- @property (nonatomic, strong, readonly) YapDatabaseSerializer objectSerializer;
198
- @property (nonatomic, strong, readonly) YapDatabaseDeserializer objectDeserializer;
199
-
200
- @property (nonatomic, strong, readonly) YapDatabaseSerializer metadataSerializer;
201
- @property (nonatomic, strong, readonly) YapDatabaseDeserializer metadataDeserializer;
202
-
203
- @property (nonatomic, strong, readonly) YapDatabaseSanitizer objectSanitizer;
204
- @property (nonatomic, strong, readonly) YapDatabaseSanitizer metadataSanitizer;
205
-
206
- /**
207
- * The snapshot number is the internal synchronization state primitive for the database.
208
- * It's generally only useful for database internals,
209
- * but it can sometimes come in handy for general debugging of your app.
210
- *
211
- * The snapshot is a simple 64-bit number that gets incremented upon every readwrite transaction
212
- * that makes modifications to the database. Due to the concurrent architecture of YapDatabase,
213
- * there may be multiple concurrent connections that are inspecting the database at similar times,
214
- * yet they are looking at slightly different "snapshots" of the database.
215
- *
216
- * The snapshot number may thus be inspected to determine (in a general fashion) what state the connection
217
- * is in compared with other connections.
218
- *
219
- * YapDatabase.snapshot = most up-to-date snapshot among all connections
220
- * YapDatabaseConnection.snapshot = snapshot of individual connection
221
- *
222
- * Example:
223
- *
224
- * YapDatabase *database = [[YapDatabase alloc] init...];
225
- * database.snapshot; // returns zero
226
- *
227
- * YapDatabaseConnection *connection1 = [database newConnection];
228
- * YapDatabaseConnection *connection2 = [database newConnection];
229
- *
230
- * connection1.snapshot; // returns zero
231
- * connection2.snapshot; // returns zero
232
- *
233
- * [connection1 readWriteWithBlock:^(YapDatabaseReadWriteTransaction *transaction){
234
- * [transaction setObject:objectA forKey:keyA];
235
- * }];
236
- *
237
- * database.snapshot; // returns 1
238
- * connection1.snapshot; // returns 1
239
- * connection2.snapshot; // returns 1
240
- *
241
- * [connection1 asyncReadWriteWithBlock:^(YapDatabaseReadWriteTransaction *transaction){
242
- * [transaction setObject:objectB forKey:keyB];
243
- * [NSThread sleepForTimeInterval:1.0]; // sleep for 1 second
244
- *
245
- * connection1.snapshot; // returns 1 (we know it will turn into 2 once the transaction completes)
246
- * } completion:^{
247
- *
248
- * connection1.snapshot; // returns 2
249
- * }];
250
- *
251
- * [connection2 asyncReadWithBlock:^(YapDatabaseReadTransaction *transaction){
252
- * [NSThread sleepForTimeInterval:5.0]; // sleep for 5 seconds
253
- *
254
- * connection2.snapshot; // returns 1. See why?
255
- * }];
256
- *
257
- * It's because connection2 started its transaction when the database was in snapshot 1.
258
- * Thus, for the duration of its transaction, the database remains in that state.
259
- *
260
- * However, once connection2 completes its transaction, it will automatically update itself to snapshot 2.
261
- *
262
- * In general, the snapshot is primarily for internal use.
263
- * However, it may come in handy for some tricky edge-case bugs (why doesn't my connection see that other commit?)
264
- **/
265
- @property (atomic, assign, readonly) uint64_t snapshot;
266
-
267
- ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
268
- #pragma mark Defaults
269
- ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
270
-
271
- /**
272
- * Allows you to set the default objectCacheEnabled and objectCacheLimit for all new connections.
273
- *
274
- * When you create a connection via [database newConnection], that new connection will inherit
275
- * its initial configuration via the default values configured for the parent database.
276
- * Of course, the connection may then override these default configuration values, and configure itself as needed.
277
- *
278
- * Changing the default values only affects future connections that will be created.
279
- * It does not affect connections that have already been created.
280
- *
281
- * The default defaultObjectCacheEnabled is YES.
282
- * The default defaultObjectCacheLimit is 250.
283
- *
284
- * For more detailed documentation on these properties, see the YapDatabaseConnection header file.
285
- * @see YapDatabaseConnection objectCacheEnabled
286
- * @see YapDatabaseConnection objectCacheLimit
287
- **/
288
- @property (atomic, assign, readwrite) BOOL defaultObjectCacheEnabled;
289
- @property (atomic, assign, readwrite) NSUInteger defaultObjectCacheLimit;
290
-
291
- /**
292
- * Allows you to set the default metadataCacheEnabled and metadataCacheLimit for all new connections.
293
- *
294
- * When you create a connection via [database newConnection], that new connection will inherit
295
- * its initial configuration via the default values configured for the parent database.
296
- * Of course, the connection may then override these default configuration values, and configure itself as needed.
297
- *
298
- * Changing the default values only affects future connections that will be created.
299
- * It does not affect connections that have already been created.
300
- *
301
- * The default defaultMetadataCacheEnabled is YES.
302
- * The default defaultMetadataCacheLimit is 500.
303
- *
304
- * For more detailed documentation on these properties, see the YapDatabaseConnection header file.
305
- * @see YapDatabaseConnection metadataCacheEnabled
306
- * @see YapDatabaseConnection metadataCacheLimit
307
- **/
308
- @property (atomic, assign, readwrite) BOOL defaultMetadataCacheEnabled;
309
- @property (atomic, assign, readwrite) NSUInteger defaultMetadataCacheLimit;
310
-
311
- /**
312
- * Allows you to set the default objectPolicy and metadataPolicy for all new connections.
313
- *
314
- * When you create a connection via [database newConnection], that new connection will inherit
315
- * its initial configuration via the default values configured for the parent database.
316
- * Of course, the connection may then override these default configuration values, and configure itself as needed.
317
- *
318
- * Changing the default values only affects future connections that will be created.
319
- * It does not affect connections that have already been created.
320
- *
321
- * The default defaultObjectPolicy is YapDatabasePolicyContainment.
322
- * The default defaultMetadataPolicy is YapDatabasePolicyContainment.
323
- *
324
- * For more detailed documentation on these properties, see the YapDatabaseConnection header file.
325
- * @see YapDatabaseConnection objectPolicy
326
- * @see YapDatabaseConnection metadataPolicy
327
- **/
328
- @property (atomic, assign, readwrite) YapDatabasePolicy defaultObjectPolicy;
329
- @property (atomic, assign, readwrite) YapDatabasePolicy defaultMetadataPolicy;
330
-
331
- #if TARGET_OS_IPHONE
332
- /**
333
- * Allows you to set the default autoFlushMemoryFlags for all new connections.
334
- *
335
- * When you create a connection via [database newConnection], that new connection will inherit
336
- * its initial configuration via the default values configured for the parent database.
337
- * Of course, the connection may then override these default configuration values, and configure itself as needed.
338
- *
339
- * Changing the default values only affects future connections that will be created.
340
- * It does not affect connections that have already been created.
341
- *
342
- * The default defaultAutoFlushMemoryFlags is YapDatabaseConnectionFlushMemoryFlags_All.
343
- *
344
- * For more detailed documentation on these properties, see the YapDatabaseConnection header file.
345
- * @see YapDatabaseConnection autoFlushMemoryFlags
346
- **/
347
- @property (atomic, assign, readwrite) int defaultAutoFlushMemoryFlags;
348
- #endif
349
-
350
- ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
351
- #pragma mark Connections
352
- ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
353
-
354
- /**
355
- * Creates and returns a new connection to the database.
356
- * It is through this connection that you will access the database.
357
- *
358
- * You can create multiple connections to the database.
359
- * Each invocation of this method creates and returns a new connection.
360
- *
361
- * Multiple connections can simultaneously read from the database.
362
- * Multiple connections can simultaneously read from the database while another connection is modifying the database.
363
- * For example, the main thread could be reading from the database via connection A,
364
- * while a background thread is writing to the database via connection B.
365
- *
366
- * However, only a single connection may be writing to the database at any one time.
367
- *
368
- * A connection is thread-safe, and operates by serializing access to itself.
369
- * Thus you can share a single connection between multiple threads.
370
- * But for conncurrent access between multiple threads you must use multiple connections.
371
- *
372
- * You should avoid creating more connections than you need.
373
- * Creating a new connection everytime you need to access the database is a recipe for foolishness.
374
- **/
375
- - (YapDatabaseConnection *)newConnection;
376
-
377
- ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
378
- #pragma mark Extensions
379
- ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
380
-
381
- /**
382
- * Registers the extension with the database using the given name.
383
- * After registration everything works automatically using just the extension name.
384
- *
385
- * The registration process is equivalent to a readwrite transaction.
386
- * It involves persisting various information about the extension to the database,
387
- * as well as possibly populating the extension by enumerating existing rows in the database.
388
- *
389
- * @return
390
- * YES if the extension was properly registered.
391
- * NO if an error occurred, such as the extensionName is already registered.
392
- *
393
- * @see asyncRegisterExtension:withName:completionBlock:
394
- * @see asyncRegisterExtension:withName:completionBlock:completionQueue:
395
- **/
396
- - (BOOL)registerExtension:(YapDatabaseExtension *)extension withName:(NSString *)extensionName;
397
-
398
- /**
399
- * Asynchronoulsy starts the extension registration process.
400
- * After registration everything works automatically using just the extension name.
401
- *
402
- * The registration process is equivalent to a readwrite transaction.
403
- * It involves persisting various information about the extension to the database,
404
- * as well as possibly populating the extension by enumerating existing rows in the database.
405
- *
406
- * An optional completion block may be used.
407
- * If the extension registration was successful then the ready parameter will be YES.
408
- *
409
- * The completionBlock will be invoked on the main thread (dispatch_get_main_queue()).
410
- **/
411
- - (void)asyncRegisterExtension:(YapDatabaseExtension *)extension
412
- withName:(NSString *)extensionName
413
- completionBlock:(void(^)(BOOL ready))completionBlock;
414
-
415
- /**
416
- * Asynchronoulsy starts the extension registration process.
417
- * After registration everything works automatically using just the extension name.
418
- *
419
- * The registration process is equivalent to a readwrite transaction.
420
- * It involves persisting various information about the extension to the database,
421
- * as well as possibly populating the extension by enumerating existing rows in the database.
422
- *
423
- * An optional completion block may be used.
424
- * If the extension registration was successful then the ready parameter will be YES.
425
- *
426
- * Additionally the dispatch_queue to invoke the completion block may also be specified.
427
- * If NULL, dispatch_get_main_queue() is automatically used.
428
- **/
429
- - (void)asyncRegisterExtension:(YapDatabaseExtension *)extension
430
- withName:(NSString *)extensionName
431
- completionBlock:(void(^)(BOOL ready))completionBlock
432
- completionQueue:(dispatch_queue_t)completionQueue;
433
-
434
- /**
435
- * This method unregisters an extension with the given name.
436
- * The associated underlying tables will be dropped from the database.
437
- *
438
- * Note 1:
439
- * You can unregister an extension that was hasn't been registered. For example,
440
- * you've previously registered an extension (in previous app launches), but you no longer need the extension.
441
- * You don't have to bother creating and registering the unneeded extension,
442
- * just so you can unregister it and have the associated tables dropped.
443
- * The database persists information about registered extensions, including the associated class of an extension.
444
- * So you can simply pass the name of the extension, and the database system will use the associated class to
445
- * drop the appropriate tables.
446
- *
447
- * Note:
448
- * You don't have to worry about unregistering extensions that you no longer need.
449
- *
450
- * @see asyncUnregisterExtension:completionBlock:
451
- * @see asyncUnregisterExtension:completionBlock:completionQueue:
452
- **/
453
- - (void)unregisterExtension:(NSString *)extensionName;
454
-
455
- /**
456
- * Asynchronoulsy starts the extension unregistration process.
457
- *
458
- * The unregistration process is equivalent to a readwrite transaction.
459
- * It involves deleting various information about the extension from the database,
460
- * as well as possibly dropping related tables the extension may have been using.
461
- *
462
- * An optional completion block may be used.
463
- *
464
- * The completionBlock will be invoked on the main thread (dispatch_get_main_queue()).
465
- **/
466
- - (void)asyncUnregisterExtension:(NSString *)extensionName
467
- completionBlock:(dispatch_block_t)completionBlock;
468
-
469
- /**
470
- * Asynchronoulsy starts the extension unregistration process.
471
- *
472
- * The unregistration process is equivalent to a readwrite transaction.
473
- * It involves deleting various information about the extension from the database,
474
- * as well as possibly dropping related tables the extension may have been using.
475
- *
476
- * An optional completion block may be used.
477
- *
478
- * Additionally the dispatch_queue to invoke the completion block may also be specified.
479
- * If NULL, dispatch_get_main_queue() is automatically used.
480
- **/
481
- - (void)asyncUnregisterExtension:(NSString *)extensionName
482
- completionBlock:(dispatch_block_t)completionBlock
483
- completionQueue:(dispatch_queue_t)completionQueue;
484
-
485
- /**
486
- * Returns the registered extension with the given name.
487
- * The returned object will be a subclass of YapDatabaseExtension.
488
- **/
489
- - (id)registeredExtension:(NSString *)extensionName;
490
-
491
- /**
492
- * Returns all currently registered extensions as a dictionary.
493
- * The key is the registed name (NSString), and the value is the extension (YapDatabaseExtension subclass).
494
- **/
495
- - (NSDictionary *)registeredExtensions;
496
-
497
- ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
498
- #pragma mark Connection Pooling
499
- ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
500
-
501
- /**
502
- * As recommended in the "Performance Primer" ( https://github.com/yaptv/YapDatabase/wiki/Performance-Primer )
503
- *
504
- * > You should consider connections to be relatively heavy weight objects.
505
- * >
506
- * > OK, truth be told they're not really that heavy weight. I'm just trying to scare you.
507
- * > Because in terms of performance, you get a lot of bang for your buck if you recycle your connections.
508
- *
509
- * However, experience has shown how easy it is to neglect this information.
510
- * Perhaps because it's just so darn easy to create a connection that it becomes easy to forgot
511
- * that connections aren't free.
512
- *
513
- * Whatever the reason, the connection pool was designed to alleviate some of the overhead.
514
- * The most expensive component of a connection is the internal sqlite database connection.
515
- * The connection pool keeps these internal sqlite database connections around in a pool to help recycle them.
516
- *
517
- * So when a connection gets deallocated, it returns the sqlite database connection to the pool.
518
- * And when a new connection gets created, it can recycle a sqlite database connection from the pool.
519
- *
520
- * This property sets a maximum limit on the number of items that will get stored in the pool at any one time.
521
- *
522
- * The default value is 5.
523
- *
524
- * See also connectionPoolLifetime,
525
- * which allows you to set a maximum lifetime of connections sitting around in the pool.
526
- **/
527
- @property (atomic, assign, readwrite) NSUInteger maxConnectionPoolCount;
528
-
529
- /**
530
- * The connection pool can automatically drop "stale" connections.
531
- * That is, if an item stays in the pool for too long (without another connection coming along and
532
- * removing it from the pool to be recycled) then the connection can optionally be removed and dropped.
533
- *
534
- * This is called the connection "lifetime".
535
- *
536
- * That is, after an item is added to the connection pool to be recycled, a timer will be started.
537
- * If the connection is still in the pool when the timer goes off,
538
- * then the connection will automatically be removed and dropped.
539
- *
540
- * The default value is 90 seconds.
541
- *
542
- * To disable the timer, set the lifetime to zero (or any non-positive value).
543
- * When disabled, open connections will remain in the pool indefinitely.
544
- **/
545
- @property (atomic, assign, readwrite) NSTimeInterval connectionPoolLifetime;
546
-
547
- @end