register Observer
Convenience method, same as registerObserver where signalNext
is called automatically after the changeHandler finishes.
Since
4.5.0
Parameters
A string containing a valid query expressed in DQL.
A Map of values keyed by the placeholder name without the leading :
. Example: ["mileage": 123]
.
A DittoChangeHandler lambda which will be invoked with the results as changes occur.
Installs and returns a store observer for a query, configuring Ditto to trigger the passed in change handler whenever documents in the local store change such that the result of the matching query changes. The passed in query must be a SELECT
query, otherwise a StoreError with QueryNotSupported reason is thrown.
Return
An active DittoStoreObserver for the given query and arguments. You'll have to keep it to be able to cancel the observation by close()
-ing it. Otherwise it will remain active until the owning Ditto instance goes out of scope.
Since
4.5.0
Parameters
A string containing a valid query expressed in DQL.
A Map of values keyed by the placeholder name without the leading :
. Example: ["mileage": 123]
.
A DittoChangeHandlerWithNextSignal lambda which will be invoked with the results as changes occur.