@@ -60,7 +60,8 @@ private func == <T>(lhs: Event<T>, rhs: Event<T>) -> Bool {
60
60
/**
61
61
A default implementation of the `ParseSubscription` protocol. Suitable for `ObjectObserved`
62
62
as the subscription can be used as a SwiftUI publisher. Meaning it can serve
63
- indepedently as a ViewModel in MVVM.
63
+ indepedently as a ViewModel in MVVM. Also provides a publisher for pull responses of query such as:
64
+ `find`, `first`, `count`, and `aggregate`.
64
65
*/
65
66
@available ( macOS 10 . 15 , iOS 13 . 0 , watchOS 6 . 0 , tvOS 13 . 0 , * )
66
67
open class Subscription < T: ParseObject > : ParseSubscription , ObservableObject {
@@ -206,7 +207,10 @@ open class Subscription<T: ParseObject>: ParseSubscription, ObservableObject {
206
207
- parameter options: A set of header options sent to the server. Defaults to an empty set.
207
208
- parameter callbackQueue: The queue to return to after completion. Default value of .main.
208
209
*/
209
- open func find( explain: Bool , hint: String ? = nil , options: API . Options = [ ] , callbackQueue: DispatchQueue = . main) {
210
+ open func find( explain: Bool ,
211
+ hint: String ? = nil ,
212
+ options: API . Options = [ ] ,
213
+ callbackQueue: DispatchQueue = . main) {
210
214
query. find ( explain: explain, hint: hint, options: options, callbackQueue: callbackQueue) { result in
211
215
switch result {
212
216
@@ -246,7 +250,10 @@ open class Subscription<T: ParseObject>: ParseSubscription, ObservableObject {
246
250
- parameter options: A set of header options sent to the server. Defaults to an empty set.
247
251
- parameter callbackQueue: The queue to return to after completion. Default value of `.main`.
248
252
*/
249
- open func first( explain: Bool , hint: String ? = nil , options: API . Options = [ ] , callbackQueue: DispatchQueue = . main) {
253
+ open func first( explain: Bool ,
254
+ hint: String ? = nil ,
255
+ options: API . Options = [ ] ,
256
+ callbackQueue: DispatchQueue = . main) {
250
257
query. first ( explain: explain, hint: hint, options: options, callbackQueue: callbackQueue) { result in
251
258
switch result {
252
259
@@ -283,7 +290,10 @@ open class Subscription<T: ParseObject>: ParseSubscription, ObservableObject {
283
290
- parameter options: A set of header options sent to the server. Defaults to an empty set.
284
291
- parameter callbackQueue: The queue to return to after completion. Default value of `.main`.
285
292
*/
286
- open func count( explain: Bool , hint: String ? = nil , options: API . Options = [ ] , callbackQueue: DispatchQueue = . main) {
293
+ open func count( explain: Bool ,
294
+ hint: String ? = nil ,
295
+ options: API . Options = [ ] ,
296
+ callbackQueue: DispatchQueue = . main) {
287
297
query. count ( explain: explain, hint: hint, options: options) { result in
288
298
switch result {
289
299
0 commit comments