You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
/// Fetches the read receipts for members of this channel.
540
+
///
541
+
/// - Parameters:
542
+
/// - limit: Number of objects to return in response
543
+
/// - page: Object used for pagination to define which previous or next result page you want to fetch
544
+
/// - filter: Expression used to filter the results. Returns only these members whose properties satisfy the given expression
545
+
/// - sort: A collection to specify the sort order
546
+
/// - Returns: A `Tuple` containing a dictionary mapping user IDs to the timetoken they have read up to, and the next pagination `PubNubHashedPage` (if one exists)
Copy file name to clipboardExpand all lines: Sources/Entities/Channel.swift
+21-3Lines changed: 21 additions & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -273,7 +273,7 @@ public protocol Channel: CustomStringConvertible {
273
273
/// - limit: Number of objects to return in response
274
274
/// - page: Object used for pagination to define which previous or next result page you want to fetch
275
275
/// - filter: Expression used to filter the results. Returns only these members whose properties satisfy the given expression
276
-
/// - sort: A collection to specify the sort order. Available options are id, name, and updated
276
+
/// - sort: A collection to specify the sort order
277
277
/// - completion: The async `Result` of the method call
278
278
/// - **Success**: A `Tuple` containing an array of the members of the channel, and the next pagination `PubNubHashedPage` (if one exists)
279
279
/// - **Failure**: An `Error` describing the failure
@@ -428,12 +428,30 @@ public protocol Channel: CustomStringConvertible {
428
428
/// - Important: Keep a strong reference to the returned ``AutoCloseable`` object as long as you want to receive updates. If ``AutoCloseable`` is deallocated,
429
429
/// the stream will be canceled, and no further items will be produced. You can also stop receiving updates manually by calling ``AutoCloseable/close()``.
430
430
///
431
-
/// - Parameter callback: Defines the custom behavior to be executed when receiving a read confirmation status on the joined channel.
431
+
/// - Parameter callback: Defines the custom behavior to be executed when receiving a read confirmation status on the joined channel. The callback receives a dictionary mapping user IDs to the timetoken they have read up to.
432
432
/// - Returns: AutoCloseable Interface you can call to stop listening for message read receipts and clean up resources by invoking the close() method
433
433
func streamReadReceipts(
434
-
callback:@escaping(([Timetoken:[String]])->Void)
434
+
callback:@escaping(([String:Timetoken])->Void)
435
435
)->AutoCloseable
436
436
437
+
/// Fetches the read receipts for members of this channel.
438
+
///
439
+
/// - Parameters:
440
+
/// - limit: Number of objects to return in response
441
+
/// - page: Object used for pagination to define which previous or next result page you want to fetch
442
+
/// - filter: Expression used to filter the results. Returns only these members whose properties satisfy the given expression
443
+
/// - sort: A collection to specify the sort order
444
+
/// - completion: The async `Result` of the method call
445
+
/// - **Success**: A `Tuple` containing a dictionary mapping user IDs to the timetoken they have read up to, and the next pagination `PubNubHashedPage` (if one exists)
446
+
/// - **Failure**: An `Error` describing the failure
0 commit comments