Get the whiteboard list
This document describes how to obtain the list of whiteboards that are being shared in a room.
Prerequisites
Creat a whiteboard by referring to Create a super board.
Implementation process
- If you enter a room for the first time, you can proactively fetch the list of whiteboards created in the room.
[[ZegoSuperBoardManager sharedInstance] querySuperBoardSubViewList:^(ZegoSuperBoardError errorCode, NSArray<ZegoSuperBoardSubViewModel *> * _Nonnull superBoardViewList) {
// After subViewModelList is obtained, update the whiteboard list on the interface.
// For example, update them to the whiteboard list.
if (errorCode == ZegoSuperBoardSuccess) {
/** The whiteboard list is obtained. */
} else {
/** Failed to obtain the whiteboard list. */
}
}];- If you are already in a room, you will need to obtain the list of all whiteboards.
// Obtain the list of all existing whiteboards. For example, display them in the whiteboard list.
NSArray <ZegoSuperBoardSubViewModel *>* array = [ZegoSuperBoardManager sharedInstance].superBoardSubViewModelList;
// Process the corresponding service logic.
