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
Copy file name to clipboardExpand all lines: Sources/Entities/Channel.swift
+5-2Lines changed: 5 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -34,7 +34,10 @@ public protocol Channel: CustomStringConvertible {
34
34
/// Represents the type of the given ``Channel``
35
35
vartype:ChannelType?{get}
36
36
37
-
/// Receive updates when specific channels are added, edited or removed.
37
+
/// Receive updates when specific channels are updated or removed.
38
+
///
39
+
/// This method takes an array of fixed items and returns the full snapshot, except when an object is removed.
40
+
/// If an object is removed, the returning list will not contain it.
38
41
///
39
42
/// - Important: Keep a strong reference to the returned ``AutoCloseable`` object as long as you want to receive updates. If ``AutoCloseable`` is deallocated,
40
43
/// the stream will be canceled, and no further items will be produced. You can also stop receiving updates manually by calling ``AutoCloseable/close()``.
@@ -387,7 +390,7 @@ public protocol Channel: CustomStringConvertible {
387
390
/// - Important: Keep a strong reference to the returned ``AutoCloseable`` object as long as you want to receive updates. If ``AutoCloseable`` is deallocated,
388
391
/// the stream will be canceled, and no further items will be produced. You can also stop receiving updates manually by calling ``AutoCloseable/close()``.
389
392
///
390
-
/// - Parameter callback: Function that takes a single Channel object. It defines the custom behavior to be executed when detecting channel changes
393
+
/// - Parameter callback: A closure to be executed when detecting channel changes. Takes a single Channel object or `nil` if the channel was removed
391
394
/// - Returns: ``AutoCloseable`` interface that lets you stop receiving channel-related updates (objects events) and clean up resources by invoking the `close()` method
Copy file name to clipboardExpand all lines: Sources/Entities/Membership.swift
+6-3Lines changed: 6 additions & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -34,7 +34,10 @@ public protocol Membership: CustomStringConvertible {
34
34
/// Timetoken of the last message a user read on a given channel
35
35
varlastReadMessageTimetoken:Timetoken?{get}
36
36
37
-
/// Receive updates when specific memberships are added, edited or removed.
37
+
/// Receive updates when specific memberships are updated or removed.
38
+
///
39
+
/// This method takes an array of fixed items and returns the full snapshot, except when an object is removed.
40
+
/// If an object is removed, the returning list will not contain it.
38
41
///
39
42
/// - Important: Keep a strong reference to the returned ``AutoCloseable`` object as long as you want to receive updates. If ``AutoCloseable`` is deallocated,
40
43
/// the stream will be canceled, and no further items will be produced. You can also stop receiving updates manually by calling ``AutoCloseable/close()``.
@@ -94,12 +97,12 @@ public protocol Membership: CustomStringConvertible {
94
97
completion:((Swift.Result<UInt64?,Error>)->Void)?
95
98
)
96
99
97
-
/// You can receive updates when specific user-channel Membership object(s) are added, edited, or removed.
100
+
/// You can receive updates when this user-channel Membership object is updated or removed.
98
101
///
99
102
/// - Important: Keep a strong reference to the returned ``AutoCloseable`` object as long as you want to receive updates. If ``AutoCloseable`` is deallocated,
100
103
/// the stream will be canceled, and no further items will be produced. You can also stop receiving updates manually by calling ``AutoCloseable/close()``.
101
104
///
102
-
/// - Parameter callback: Defines the custom behavior to be executed when detecting membership changes
105
+
/// - Parameter callback: A closure to be executed when detecting membership changes. Takes a Membership object or `nil` if the membership was removed
103
106
/// - Returns: An ``AutoCloseable`` that you can use to stop receiving objects events by invoking its ``AutoCloseable/close()`` method
Copy file name to clipboardExpand all lines: Sources/Entities/Message.swift
+4-1Lines changed: 4 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -61,7 +61,10 @@ public protocol Message: CustomStringConvertible {
61
61
/// Error associated with the message, if any
62
62
varerror:Error?{get}
63
63
64
-
/// Receive updates when specific messages and related message reactions are added, edited, or removed.
64
+
/// Receive updates when specific messages and related message reactions are updated or removed.
65
+
///
66
+
/// This method takes an array of fixed items and returns the full snapshot, except when an object is removed.
67
+
/// If an object is removed, the returning list will not contain it.
65
68
///
66
69
/// - Important: Keep a strong reference to the returned ``AutoCloseable`` object as long as you want to receive updates. If ``AutoCloseable`` is deallocated,
67
70
/// the stream will be canceled, and no further items will be produced. You can also stop receiving updates manually by calling ``AutoCloseable/close()``.
Copy file name to clipboardExpand all lines: Sources/Entities/User.swift
+5-2Lines changed: 5 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -42,7 +42,10 @@ public protocol User: CustomStringConvertible {
42
42
/// Indicates whether the user is currently (at the time of obtaining this ``User`` object) active
43
43
varactive:Bool{get}
44
44
45
-
/// Receive updates when specific users are added, edited or removed.
45
+
/// Receive updates when specific users are updated or removed.
46
+
///
47
+
/// This method takes an array of fixed items and returns the full snapshot, except when an object is removed.
48
+
/// If an object is removed, the returning list will not contain it.
46
49
///
47
50
/// - Important: Keep a strong reference to the returned ``AutoCloseable`` object as long as you want to receive updates. If ``AutoCloseable`` is deallocated,
48
51
/// the stream will be canceled, and no further items will be produced. You can also stop receiving updates manually by calling ``AutoCloseable/close()``.
@@ -156,7 +159,7 @@ public protocol User: CustomStringConvertible {
156
159
/// the stream will be canceled, and no further items will be produced. You can also stop receiving updates manually by calling ``AutoCloseable/close()``.
157
160
///
158
161
/// - Parameters:
159
-
/// - callback: A function that is triggered whenever the user's information are changed (added, edited, or removed)
162
+
/// - callback: A closure to be executed when detecting user changes. Takes a User object or `nil` if the user was removed
160
163
/// - Returns: An ``AutoCloseable`` that you can use to stop receiving objects events by invoking its ``AutoCloseable/close()`` method
0 commit comments