Commit Graph
2718 Commits
Author SHA1 Message Date
Gwendal Roué 022fee8788 Remove dead code 2020-03-27 20:48:12 +01:00
Gwendal Roué 25a2bd653c Fix compiler warning 2020-03-27 20:48:03 +01:00
Gwendal Roué c03de9cc16 Fix documentation 2020-03-27 20:45:24 +01:00
Gwendal Roué 97d06a0fae Fix typo 2020-03-27 20:36:29 +01:00
Gwendal Roué c4b7e0017b The main thread is enough 2020-03-27 20:19:44 +01:00
Gwendal Roué 469814985e Decrease nesting 2020-03-27 19:55:36 +01:00
Gwendal Roué f16105ad03 Add missing cancellation checks 2020-03-27 19:53:01 +01:00
Gwendal Roué 4309eaba64 Scheduling of fresh values is no longer an attribute of ValueObservation 2020-03-27 19:49:11 +01:00
Gwendal Roué b4b5d9b602 Simplify ValueObservation scheduling 2020-03-27 08:27:30 +01:00
Gwendal Roué e68bd077ee Remove all observationForCount/All/First methods 2020-03-25 21:44:10 +01:00
Gwendal Roué 79d6b02a2f Cleanup 2020-03-25 13:57:49 +01:00
Gwendal Roué 1195439226 Cleanup 2020-03-25 13:53:22 +01:00
Gwendal Roué ff2629a31c Cleanup 2020-03-25 13:05:39 +01:00
Gwendal Roué 61e74f9ad4 ValueObservation.trackingVaryingRegion documentation 2020-03-25 08:48:34 +01:00
Gwendal Roué f711978145 Documentation 2020-03-25 08:25:05 +01:00
Gwendal Roué a647e200d9 Replace Never with ValueReducers.Auto 2020-03-25 08:19:47 +01:00
Gwendal Roué 294a04e9f6 Rename tracking(value:) to tracking(_:) 2020-03-25 08:11:43 +01:00
Gwendal Roué 9792edc008 Rename trackingVolatile to trackingVaryingRegion 2020-03-25 00:13:51 +01:00
Gwendal Roué 121f7be847 ValueObservation is now fully based on region recording
And we introduce ValueObservation.trackingVolatile
2020-03-24 23:52:05 +01:00
Gwendal Roué 4af7fda4f2 Fix outdated documentation 2020-03-24 23:49:24 +01:00
Gwendal Roué 56f332122d The observed region is always recorded 2020-03-24 22:59:07 +01:00
Gwendal Roué d494d12293 Fix typo 2020-03-24 22:59:07 +01:00
Gwendal Roué dfd5dd2478 Add missing import for SPM 2020-03-24 22:55:18 +01:00
Gwendal Roué 0c464def7f Fix documentation 2020-03-23 18:00:45 +01:00
Gwendal Roué 3ee231afd3 Cleanup _OptionalProtocol 2020-03-21 14:36:48 +01:00
Gwendal Roué 2150b6688a Fix ValueObserver cancellation 2020-03-21 14:36:48 +01:00
Gwendal Roué 2bb894108c Use the prependingConcurrentFetch flag 2020-03-21 14:36:48 +01:00
Gwendal Roué 26d2245ae8 Asynchronouslu remove observer when it is cancelled 2020-03-21 14:36:48 +01:00
Gwendal Roué 2b78a646ed Mor preparation for initiial concurrent fetch of ValueObservation in a DatabasePool 2020-03-21 14:36:48 +01:00
Gwendal Roué 1c59278115 Prefer dbResult argument name for async read closures 2020-03-21 14:36:48 +01:00
Gwendal Roué 2824636650 Prepare for initiial concurrent fetch of ValueObservation in a DatabasePool 2020-03-21 14:36:48 +01:00
Gwendal Roué 5a884ad93d Common ValueObservation code for all read-only database accessors 2020-03-21 14:36:48 +01:00
Gwendal Roué dab8e28f6d Merge branch 'master' into GRDB5
# Conflicts:
#	GRDB/Migration/DatabaseMigrator.swift
#	GRDB/QueryInterface/Request/QueryInterfaceRequest.swift
#	README.md
2020-03-21 14:35:57 +01:00
Gwendal Roué c1d1797576 Address #725 2020-03-18 20:36:56 +01:00
Gwendal Roué a0faf6aa68 Support for nil assignment 2020-03-18 19:34:43 +01:00
Gwendal Roué c698b30c0a Add fixits 2020-03-12 07:43:57 +01:00
Gwendal Roué dfa40ea18f Rename ValueObservation.fetchFirst to fetchValue
"First", in Swift, hints that the result is optional. But the result of this function is no longer optional.
2020-03-12 07:34:43 +01:00
Gwendal Roué 936c92eba6 All value reducers must emit an initial value
This disqualifies compactMap as a valid ValueObservation transformation: it has been removed.

This simplifies implementation as well.
2020-03-12 07:18:40 +01:00
Gwendal Roué bf3f97b64d Fix compiler warning 2020-03-11 22:42:48 +01:00
Gwendal Roué 5e0535d511 ValueReducer creation does not need database access 2020-03-11 22:00:07 +01:00
Gwendal Roué b96d71d937 Remove public ValueObservation factory methods that accept a _ValueReducer 2020-03-11 21:38:48 +01:00
Gwendal Roué 28c32c6af8 _ValueReducer is the only protocol accepted by ValueObservation
Also, we now use Never as the bottom reducer which helps us define the ValueObservation factory methods.
2020-03-11 21:38:41 +01:00
Gwendal Roué f80c5ce348 Make the ValueReducer protocol unavailable
# Conflicts:
#	GRDB/ValueObservation/ValueReducer/ValueReducer.swift
2020-03-11 21:38:20 +01:00
Gwendal Roué 4f74997235 Restore old disabled tests for cancelled ValueObservation 2020-03-10 22:06:41 +01:00
Gwendal Roué 2f4187b084 DatabaseWriter.remove(transactionObserver:) can run from the writer queue 2020-03-10 22:06:08 +01:00
Gwendal Roué 9a6d6cf9c0 Update documentation for ValueObservation scheduling 2020-03-10 22:04:58 +01:00
Gwendal Roué d66f2c8cfd Simplify ValueObservation starting process 2020-03-10 20:50:06 +01:00
Gwendal Roué 6f239a5ad3 All ValueObservationScheduling cases now trigger an initial fetch 2020-03-10 19:42:58 +01:00
Gwendal Roué 2224042114 Rename ValueScheduling to ValueObservationScheduling 2020-03-10 19:10:38 +01:00
Gwendal Roué 4fe201f8aa Merge branch 'development' into GRDB5 2020-03-10 19:05:29 +01:00