Social+ Docs
About UsDeveloper PortalArchives
  • Social+
  • Announcements
  • Technical FAQ
  • Getting Started
    • Installation and Authentication
      • Install iOS SDK
      • Install Android SDK
      • Install JavaScript SDK (Deprecated)
      • Install TypeScript SDK
      • Install Flutter SDK
      • Install SDK for Ionic
    • Tutorials
  • Social+ SDK
    • Core Concepts
      • Session State
      • User
        • Create User
        • Get User Information
        • Search and Query Users
        • Update User Information
        • Delete User
        • Roles & Permissions
        • User Token Management
        • Flag / Unflag User
      • Files, Images, and Videos
        • File Handling
        • Image Handling
        • Video Handling
      • Push Notifications
        • iOS Push Notification Certificate Setup
        • Android Push Notifications Initialization
        • React Native Push Notifications Initialization
        • Register and Unregister Push Notifications on a Device
        • Push Notification Toggles
          • User Push Notification Settings
          • Channel Push Notification Settings
          • Community Push Notification Settings
      • Mentions
      • Poll
      • Ads
        • Get Ads and Settings
        • Ad Impressions
      • Presence State
        • Heartbeat Sync
        • User Presence
        • Channel Presence
      • Live Objects/Collections
        • iOS Live Objects/Collections
        • Android Live Objects/Collections
        • Javascript Live Objects/Collections
        • TypeScript Live Objects/Collections
        • Flutter Live Objects/Collections
      • Realtime Events
        • Social Realtime Events
        • Chat Realtime Events
      • Error Handling
      • Content Moderation
      • Logging
    • Chat
      • Channels
        • Create Channel
        • Query Channels
        • Get Channel
        • Get Channels
        • Update Channel
        • Join/Leave Channel
        • Subchannel
        • Message Preview
        • Unread Count
          • Channel Unread Count
          • Start / stop message read receipt sync
          • Mark Message as Read
          • Message Delivery Status
          • Observe reading count
        • Read Status & Unread Count (Legacy)
        • Channel Moderation
        • Query Members
        • Search Members
        • Archive Channels
      • Messaging
        • Send a Message
          • Text Message
          • Image Message
          • Audio Message
          • Video Message
          • File Message
          • Custom Message
          • Reply to a Message
        • Query and Filter Messages
        • Get and View a Message
        • Edit and Delete Messages
        • Message Reaction
        • Mention in Messages
        • Flag/Unflag a Message
      • Moderation
        • Roles and Permission
        • Mute/Unmute a List of Channel Members
        • Ban/Unban a List of Channel Members
        • Channel Rate-Limiting
    • Social
      • Posts
        • Create Post
          • Text Post
          • Image Post
          • File Post
          • Video Post
          • Live stream Post
          • Poll Post
          • Custom Post
        • Query Post
        • Get Post
        • Viewing Post Content
        • Edit Post
        • Delete Post
        • Mention in Post
        • Flag / Unflag Post
        • Post Review
        • Post Impression
        • Pinned Post
      • Stories
        • Get Global Story Targets
        • Create Story
        • Get Stories
        • Delete Story
        • Get Story Targets
        • Story Impressions
      • Comments
        • Create Comment
        • Query Comment
        • View Comment
        • Get Comment
        • Get Latest Comment
        • Edit Comment
        • Delete Comment
        • Flag/Unflag
        • Get Comment Reaction Data
        • Mention in Comment
      • Reactions
        • Query Reactions
        • Add / Remove Reaction
      • Feed
        • Custom Post Ranking
        • Query Global Feed
      • Communities
        • Create Community
        • Get Community
        • Query Communities
        • Update Community
        • Delete Community
        • Join/Leave Community
        • Trending and Recommended Communities
        • Query Community Members
        • Community Moderation
        • Community Categories
      • Follow/Unfollow
        • Get Connection Status and Connection Counter
        • Follow/Unfollow User
        • Get Follower/Following List
        • Accept/Decline Follow Request
      • Block and Unblock User
      • Intelligent Search
        • Intelligent Search - Post
        • Intelligent Search - Community
      • Notification tray
        • Get Notification Tray Seen
        • Mark Notification Tray Seen
        • Query Notification Tray Item
        • Mark Notification Tray Item Seen
    • Video
      • iOS
        • View & Play Live Stream
        • Broadcast Live Stream
        • Push Notifications
      • Android
        • View & Play Live Stream
        • Broadcast Live Stream
        • Push Notifications
      • Flutter
        • View & Play Live Stream
        • Push Notifications
      • Web
        • View & Play Live Stream
        • Create Live Stream
        • Push Notifications
      • TypeScript (Beta)
        • RunQuery Pattern
        • Live Stream
      • React Native
        • View & Play Live Stream
        • Broadcast Live Stream
    • Changelogs & Versioning
      • iOS
      • Android
      • TypeScript
      • React Native
      • Flutter (Beta)
      • React Native (Video)
      • JavaScript (Deprecated)
  • Social+ UIKit
    • UIKit 4
      • Installation Guide
        • iOS
        • Android
        • Web React
        • Flutter (Beta)
        • React Native (Beta)
      • Setup and Authentication
        • iOS
        • Android
        • Web React
        • Flutter (Beta)
        • React Native (Beta)
      • Customization
        • Remote Config
        • Customization Basics
        • Overriding Navigation Behaviour
      • Social
        • Discover & Search
          • Social Home Page
            • Top Navigation Component
            • Newsfeed Component
            • Empty Newsfeed Component
            • Global Feed Component
            • Create Post Menu Component
            • Community Categories Component
            • Recommended Communities Component
            • Trending Communities Component
          • Global Search Page
            • Top Search Bar Component
            • Community Search Result Component
            • User Search Result Component
          • My Communities Search Page
          • All Categories Page
          • Communities By Category Page
          • Notification Tray
        • Community
          • Community Setup Page
            • Add Category Page
            • Add Member Page
          • Community Profile Page
            • Community Header Component
            • Community Feed Component
            • Community Pin Feed Component
            • Community Image Feed Component
            • Community Video Feed Component
          • Pending Post Page
            • Pending Post Content Component
          • Community Setting Page
            • Community Notification Setting Page
              • Community Posts Notification Page
              • Community Comments Notification Page
              • Community Stories Notification Page
            • Community Post Permissions Page
            • Community Story Setting Page
          • Community Membership Page
        • User
          • User Profile Page
            • User Profile Header Component
            • User Feed Component
            • User Image Feed Component
            • User Video Feed Component
          • Edit User Profile Page
          • Blocked User Page
          • User Relationship Page
          • User Pending Follow Request Page
        • Post
          • Post Details Page
            • Post Content Component
          • Post Composer Page
            • Media Attachment Component
            • Detailed Media Attachment Component
          • Post Target Selection Page
          • Poll Post Composer Page
          • Poll Target Selection Page
        • Livestream
          • Livestream Target Selection Page
          • Livestream Creation Page
          • Livestream Player Page
          • Livestream Terminated Page
        • Story
          • Story Target Tab Component
          • Story Creation Page
            • Story Drafting Page
          • Story Viewing Page
          • Story Target Selection Page
        • Comment & Reaction
          • Comment Tray Component
          • Reaction List Component
        • Content moderation
      • Chat
        • Recent chats (channel list)
          • Chat Home Page
          • Chat List Component
          • Archived Chat List Component
          • Amity Channel Create Conversation Page
        • Conversation Chat
          • AmityChatPage
          • AmityMessageComposer
        • Live Chat
          • Live Chat Page
            • Live Chat Header Component
            • Live Chat Message List Component
              • Reaction List Component
            • Live Chat Compose Bar Component
    • UIKit 3
      • iOS (Deprecated)
        • Overview
        • iOS UIKit Installation Guide
        • Installing UIKit (deprecated)
        • Setup & Authentication
        • Using Themes
        • Social UIKit
          • Using as a whole feature with the default settings
          • Our Components
            • Community Home Page
              • Newsfeed
                • Global Feed
                • My Community Preview
              • Explore Tab
                • Recommended Community
                • Top Trending
                • Categories
            • My Community Page
            • Category List Page
            • Community List by Category Page
            • Community Creation Page
            • Community Profile Edit Page
            • Community Setting Page
              • Community Push Notification Settings Page
                • Community Push Notification Settings - Comment and Reply Relate Event Page
                • Community Push Notification Settings - Post Relate Event Page
            • Post Creation Page
              • Livestream Post
            • Post Detail Page
            • Post Edit Page
            • Comment Creation
            • Comment Edit Page
            • Community Profile Page
              • Community Feed
              • Media Gallery
            • Community Member Page
            • User Profile Page
              • User Feed
            • User Profile Page (2.2)
              • User Feed (2.2)
            • User Setting Page(2.2)
            • User Profile Edit Page
            • Following / Follower User List Page (2.2)
            • Follow Request Page (2.2)
            • Member Selection Page
            • Post Target Selection Page
          • Using Your Own Component
            • Using Your Own Navigation Bar
          • Overriding UIKit Behaviour
            • Feed UI Settings
              • Post Sharing
              • Post Rendering
            • Event Handling
              • Example
          • Roles & Permissions
        • Chat UIKit
          • Using as a Whole Feature with the Default Settings
          • Using Only Some Components
            • Chat Home Page
              • Recent chat
            • Chat Room Page
          • Using your own component
            • Message Bubble
        • Video UIKit
          • Livestream
      • Android (Deprecated)
        • Overview
        • Android UIKit Installation Guide
        • Installing UIKit (deprecated)
        • Setup & Authentication
        • Using Themes
        • Social UIKit
          • Using as a whole feature with the default settings
          • Our Components
            • Community Home Page
              • Newsfeed
                • Global Feed
                • My Community Preview
              • Explore Tab
                • Recommended Community
                • Top Trending Community
                • Categories
            • My Community Page
            • Category List Page
            • Community List By Category Page
            • Community Creation Page
            • Community Profile Edit Page
            • Post Creation Page
              • Livestream Post
            • Post Details Page
            • Post Edit Page
            • Comment Creation
            • Comment Edit Page
            • Community Profile Page (2.5)
              • Community Feed (2.5)
              • Media Gallery
            • Community Member Page
            • User Profile Page
              • User Feed
            • User Profile Page (2.3)
              • User Feed (2.3)
            • User Setting Page (2.3)
            • Following and Follower User List Page(2.3)
            • Follow Request Page (2.3)
            • User Profile Edit Page
            • Member Selection Page
            • Post Target Selection Page
          • Using Your Own Components
            • Using Your Own Navigation Bar
          • Overriding UIKit Behaviour
            • Overriding Global Behaviour
              • Feed UI Settings
                • Post Sharing
                • Post Rendering
            • Event Handling
              • Example
        • Chat UIKit
          • Using as a whole feature with the default settings
          • Using Only Some Components
            • Chat Home Page
              • Recent Chat
            • Chatroom Page
          • Using Your Own Component
            • Message Bubble
      • React (Deprecated)
        • Overview
        • Web UIKit Installation Guide
        • Installing UI Kit (deprecated)
        • Setup & Authentication
        • Using Themes
        • Social UIKit
          • Using as a whole feature with the default settings
          • Our Components
            • Community Home Page
              • Search Communities
              • Newsfeed
                • Global Feed
              • Explore
                • Recommended Communities
                • Top Trending Communities
                • Categories
            • My Community
            • Community List By Category Page
            • Community Creation Page
            • Community Settings
              • Edit Profile Page
              • Members
              • Permissions
            • Post Creation
              • Livestream Post
            • Post Edit
            • Comments
            • Community Profile Page
              • Community Feed
              • Media Gallery
              • Community Members Page
              • Transfer Moderator Role
            • User Profile
              • User Feed
              • Media Gallery
              • Following / Follower User List Page
            • Follow Request Page
            • Profile Settings Page
          • Using Your Own Component
            • Using Your Own Like Button for Posts
          • Overriding UIKit Behaviour
            • Post Rendering
        • Chat UIKit
          • Using as a Whole Feature with the Default Settings
          • Our Components
            • Recent Chat
            • Chat Room
            • Message Bubble
            • Chat Details
        • Event Handling
          • Example
        • Roles & Permissions
      • Flutter (Beta)
        • Overview
        • Flutter UIKit Installation Guide
        • Setup & Authentication
        • Using Themes
        • Social UIKit
          • Using as a whole feature with the default settings
      • React Native (Beta)
        • Setup & Authentication
        • Running the Sample App with Expo
    • Changelogs
      • iOS
      • Android
      • Flutter
      • Web (React)
      • React Native
        • React Native Chat UIKit
        • React Native Social UIKit
  • Analytics & Moderation
    • Social+ Portal
      • Getting Started
      • Application Management
      • Account Management
      • Dashboard
        • Raw Data Export
      • Changelogs
    • Social+ Console
      • Moderation, Roles & Privileges
      • Chat Management
        • Channel Management
        • Message Management
        • Chat Activities (Beta)
      • Social Management
        • Communities
        • Posts
          • Post Viewing and Management
          • Post Creation
          • Post Pinning and Featuring
        • Comments
          • Comment Viewing and Management
          • Comment Creation and Reply
        • Stories
      • User & Content Management
        • User Social History
      • Admin Access Control
      • Livestream Moderation
      • Premium Ads
        • Setting Up Premium Ads
        • Setting Up Advertiser Profile
      • Settings
        • Image Moderation
        • Push Notifications
        • Security
          • Admin Token Management
        • Brand Settings
      • AI Content Moderation
      • Changelogs
    • Social+ APIs and Services
      • Network Settings
      • Generate User Last Activity Report
      • Pre-Hook Event
  • Developers
    • Developer Kits
    • Beta Features
      • Enhance Moderation
      • Search Posts API
      • Content Search V2 (Deprecated)
      • Webhook Events
      • Notification Tray
      • Block User
      • User Activity
    • Migration Guides
      • FCM legacy API Migration Guide
      • SDK v6.26.0 Unread Count Migration Guide
      • JS SDK to TS SDK Migration Guide
      • Web UIKit v3.0 Migration Guide
      • iOS UIKit V3.0 Migration Guide
      • iOS SDK v7.0.0 Migration Guide
      • iOS SDK v6.0.0 Migration Guide
        • iOS SDK v6.9.0 Deprecation Note
        • iOS SDK v6.8.0 Deprecation Note
        • iOS SDK v6.7.0 Deprecation Note
        • iOS SDK v6.5.0 Deprecation Note
      • Android SDK v7.0.0 Migration Guide
      • Android SDK v6.0.0 Migration Guide
        • Android SDK v.6.20.0 Deprecation Note
        • Android SDK v.6.19.0 Deprecation Note
        • Android SDK v6.10.0 Deprecation Note
        • Android SDK v6.9.0 Deprecation Note
        • Android SDK v6.5.0 Deprecation Note
      • TS SDK v7.0.0 Migration Guide
      • TS SDK v6.0.0 Migration Guide
        • TS SDK v6.4.6 Deprecation Note
        • TS SDK v6.8.0 Deprecation Note
      • Web SDK v5.0.0 Migration Guide
      • Flutter SDK v7.0.0 Migration Guide
      • Flutter SDK beta Migration Guide
        • Flutter SDK v0.21.0 Deprecation Note
    • SDK API Reference
      • Server API Reference
      • iOS SDK API Reference (beta)
      • Android SDK API Reference (beta)
      • Flutter SDK API Reference
  • Miscellaneous
    • Support
      • Code of conduct
      • Managed UI Kit - Deprecation
      • Contribute
      • Security
    • Announcements Archive
Powered by GitBook
On this page
  • Live Objects and Live Collections
  • How it Works
  • AmityNotificationToken
  • AmityObject
  • AmityCollection
  • SwiftUI Support
  • Access AmityObject & AmityCollection in SwiftUI views

Was this helpful?

Export as PDF
  1. Social+ SDK
  2. Core Concepts
  3. Live Objects/Collections

iOS Live Objects/Collections

Live Objects and Live Collections

In iOS Social Plus SDK, we have a concept of Live Object and Live Collection. LiveObject is represented by AmityObject an instance and LiveCollection is represented by an instance of AmityCollection. These generic classes encapsulate any other object and notify the observer whenever any property of the encapsulated object changes.

Live Object helps to observe changes in a single object whereas Live Collection helps to observe changes in a list of objects. For example: AmityObject<AmityPost> or AmityCollection<AmityMessage>.

How it Works

SDK handles a lot of data received from various sources. Data can be present in the local cache. It might also be queried from the server or received from some real-time events. This means some data is constantly updating. The data that you are accessing at the moment can get updated by other sources and become out of sync.

Live Object and Live Collection help in syncing these constantly updating data, so you will always get the most recent one. Whenever the data gets updated, you will be notified through helper methods in live objects and live collection classes.

New data gets automatically collected every time when there is an updation and the user need not refresh to get the recent data.

Live collection is available for the following functionalities in user/community feeds:

  • Post Collection

  • Comment Collection

  • Story Collection

  • User Collection

  • Reactions Collection

  • Followers/Following Collection

  • Channel Collection

  • Sub-Channel Collection

  • Message Collection

  • Channel Member Collection

  • Community Collection

  • Community Members Collection

  • Community Category Collection

  • Stream Collection

Both AmityObject and AmityCollection provide methods for observing changes in objects. The life cycle of observation is tied to its token. As soon as the token is invalidated or deallocated, observation ends.

AmityNotificationToken

AmityNotificationToken is a simple object which keeps track of what is being observed. Each Live Object or Live Collection observation is tied to its respective token. As soon as the token is invalidated or deallocated, observation ends. The token is declared within the scope of the class.

The token is used in combination with AmityObject or AmityCollection. We will explore it more in AmityObject and AmityCollection concepts.

AmityObject

AmityObject is a generic class that keeps track of a single object. It is a live object. In iOS AmitySDK, any object which is encapsulated by AmityObject is a live object.

Examples:

  • AmityObject<AmityMessage>

  • AmityObject<AmityChannel>

AmityObject class exposes the following methods:

  • observe

  • observeOnce

These methods help observe a live object. Whenever any property for the observed object changes, the observer is triggered.

Observer

observe method can be triggered multiple times throughout the lifetime of the application as long as its associated AmityNotificationToken is retained in memory. observeOnce method, on the other hand, can only be triggered once.

Both observe and observeOnce methods will be called from the main thread so you can perform any UI update-related tasks from within the observed block itself.

  • If the requested object data is stored locally on the device, the block will be called immediately with the local version of the data. This can be verified through the dataStatus property of AmityObject.

  • In parallel, a request is made to the server to fetch the latest version of the data. Once the data is returned, the observed block will be triggered again.

  • Any future changes to that data from any sources can trigger an observer.

Lifecycle: The life cycle of the observer is tied to its token. If the token is not retained, then the observer can get deallocated at any time and will not be called. Both observe and observeOnce block will be retained using token as shown below.

Invalidate token

The AmityNotificationToken provides a method called invalidate() which can be used to invalidate the token anytime. As soon as you invalidate the token, your observation stops and observe block will no longer be triggered.

Accessing Objects

There are multiple ways to access data from AmityObject. AmityObject exposes the following properties:

  • dataStatus: Indicates whether the data is fresh or local

  • loadingStatus: Indicates if the data is being loaded from server or not

  • object: The actual object that is being tracked or encapsulated by this AmityObject

Once you add an observer block, you can access both local or fresh data as shown below.

If you want to observe fresh object just once, you can check the data status and invalidate the token once you receive the fresh object.

For observerOnce method, if data is present locally, this observer will be triggered only once with that local data. If you are looking for fresh data, use the observe block and invalidate the token once fresh data is received as shown above.

If you only care about local data and do not want to observe anything, you can also access the object property from AmityObject directly.

While this is possible, we recommend accessing object from within theobserve or observeOnce block depending on your requirement.

AmityLoadingStatus

AmityObject can be tracked for their loading status by accessing the loadingStatus property, which is of type AmityLoadingStatus and it can have one of four possible values.

  • 0 (notLoading): Indicates that the data is already fresh locally and does not need to be loaded.

  • 1 (loading): Indicates that the client is currently loading the data from the server.

  • 2 (loaded) - Indicates that the client has successfully loaded fresh data from the server and is up to date.

  • 3 (error) - Indicates that the data is unable to load due from a specific error.

AmityCollection

AmityCollection is a generic class that keeps track of a collection of objects. It is a live collection. In iOS SDK, any object which is encapsulated by AmityCollection class is a live collection.

Examples:

  • AmityCollection<AmityMessage>

  • AmityCollection<AmityChannel>

AmityCollection exposes these methods:

  • observe

  • observeOnce

These methods help to observe a live collection. Whenever any property for any object within the collection changes, the observer is triggered.

Observer

observe method can get triggered multiple times throughout the lifetime of the application as long as it's associated AmityNotificationToken is retained in memory. observeOnce, on the other hand, can only be triggered once.

Both observe and observeOnce method will be called from the main thread so you can perform any UI update related task within the observe block itself.

  • If the requested data collection is stored locally on the device, the block will be called immediately with the local version of the data. This can be verified through the dataStatus property of AmityCollection.

  • In parallel, a request is made to the server to fetch the latest version of the data. Once the data is returned, the observe block will be triggered again.

  • Any future changes to the data from any sources can trigger observer.

Lifecycle: The life cycle of the observer for AmityCollection is also tied to its token. If the token is not retained, the observer can get deallocated at any time and will not be called. So, both observe and observeOnce block should be retained. You can refer to the section in AmityObject about retaining and invalidating a token.

Accessing Collection

Unlike most databases, AmityCollection does not return all data in an array. Instead, data is fetched one by one using the objectAtIndex: method. This allows the framework to store most of the actual result on disk, and load them in memory only when necessary.

AmityCollection also exposes a count property which determines the number of objects present in a collection.

With these two public interfaces, you can create a robust list UI for your use case. Similar to AmityObject, AmityCollection also exposes dataStatus and loadingStatus property.

Let's look at the typical flow when accessing a collection data.

If you want to observe only fresh or local collection, you can access it using thedataStatus property and invalidate the token once you have accessed your desired collection data.

For observerOnce method, if data is present locally, this observer will be triggered only once with that local data. If you are looking for fresh data, use observe block and invalidate the token once fresh data is received as shown above.

Observer also provides you with the AmityCollectionChange object which contains indexes of what is added, deleted, or modified in a collection. You can also refer to these properties to update the UI for the list.

Iterate through collection

While SDK provides liveCollection.object(at:) to access a single item, you might often find the need to iterate through all objects in the collection. The SDK has a convenient way to do this using .allObjects().

Using the above method is the same with this logic:

Pagination

AmityCollection in SDK returns a maximum of 20 items per page. It has nextPage() and previousPage() method to fetch more data. It also exposes hasNext and hasPrevious property to check if next page or previous page is present.

Once next page is available, the same observe block gets triggered and you can access the collection as shown above. If you want to shrink the collection to the original first page, you can do so by calling resetPage() method on the same collection.

One typical usage of Live Collection is in UITableView. Below is an example of fetching a collection and displaying it in a tableview.

SwiftUI Support

AmityObject and AmityCollection are now observable object with its properties marked with @Published annotation. Now you can use live object & live collection directly within your SwiftUI views.

Live Object
@Published
Remarks

dataStatus

✅

-

loadingStatus

✅

-

snapshot

✅

New

error

✅

-

object

❌

Deprecated

Live Collection
@Published
Remarks

dataStatus

✅

-

loadingStatus

✅

-

snapshots

✅

New

error

✅

New

Access AmityObject & AmityCollection in SwiftUI views

Since AmityObject & AmityCollection are observable object, it can be used as an ObservedObject within SwiftUI views. We recommend to create small view which observes AmityCollection & AmityObject as ObservedObject as shown in code sample below.

Live Object - SwiftUI

Live Collection - SwiftUI

Since the properties are published, If you are using Combine Framework, you can also subscribe to changes on those properties.

Live Object - Combine

Live Collection - Combine

ℹ️ States of live collection & live object are published before snapshots so that you can compare the state from within subscriber.

FAQ’s:

#1: LiveCollection is not updated when used from inside of another observable class.

AmityCollection & AmityObject is an ObservableObject. When this live collection or live object is embedded inside another Observable Object, SwiftUI cannot observe the changes in snapshot occurring within Live collection & Live object. As a result, there might be a situation where you see your view is not getting updated even when snapshot(s) are updated. This is a common problem with nested observable object in SwiftUI.

To solve this issue we recommend to create a specific view which observes AmityCollection & AmityObject as @ObservedObject as shown in code example.

#2: Published property still returns old values.

Since the properties of AmityCollection & AmityObject are marked with @Published annotation, the publishing of changes occurs in the property’s willSet block, meaning that any subscribers will receive an update before the property is changed. This behaviour can easily lead to unexpected bugs.

Last updated 6 months ago

Was this helpful?

Please make sure that the user is logged in before observing AmityObject. You can also refer to the section for more details.

Please make sure that the user is logged in before observing AmityCollection. You can also refer to section for more details.

For more details, please refer to

session state
session state
https://developer.apple.com/documentation/combine/published
AmityNotification is alive in MyClass scope.
Live Object observation is bound to a token
Invalidate a token
Accessing live object properties
Get a fresh object
Get a local data
Observe a Live Collection
Observe a Fresh Live Collection
Iterate each object in a live collection using .allObjects()
An equivalent implementation of .allObjects()
Call nextPage() / previousPage() to load more data
Using a live collection with UITableView