Extensions on
V2TIMManager
Methods
addCommunityListener(listener:)
public func addCommunityListener(listener: V2TIMCommunityListener)
1.1 Add the community listener
removeCommunityListener(listener:)
public func removeCommunityListener(listener: V2TIMCommunityListener)
1.2 Remove the community listener
createCommunity(info:memberList:succ:fail:)
public func createCommunity(info: V2TIMGroupInfo, memberList: Array<V2TIMCreateGroupMemberInfo>?, succ: V2TIMCreateGroupSucc?, fail: V2TIMFail?)
Community-Topic
2.1 Create a community that supports topics
getJoinedCommunityList(succ:fail:)
public func getJoinedCommunityList(succ: @escaping V2TIMGroupInfoListSucc, fail: @escaping V2TIMFail)
2.2 Get the list of Community-groups that the current user has joined
createTopicInCommunity(groupID:topicInfo:succ:fail:)
public func createTopicInCommunity(groupID: String, topicInfo: V2TIMTopicInfo, succ: V2TIMCreateTopicSucc?, fail: V2TIMFail?)
2.3 Create topic
Parameters
Name | Type | Description |
---|---|---|
groupID | String |
The community ID must start with @TGS#_. |
deleteTopicFromCommunity(groupID:topicIDList:succ:fail:)
public func deleteTopicFromCommunity(groupID: String, topicIDList: Array<String>, succ: V2TIMTopicOperationResultSucc?, fail: V2TIMFail?)
2.4 Delete topic
setTopicInfo(topicInfo:succ:fail:)
public func setTopicInfo(topicInfo: V2TIMTopicInfo, succ: V2TIMSucc?, fail: V2TIMFail?)
2.5 Modify topic information
getTopicInfoList(groupID:topicIDList:succ:fail:)
public func getTopicInfoList(groupID: String, topicIDList: Array<String>?, succ: @escaping V2TIMTopicInfoResultListSucc, fail: @escaping V2TIMFail)
2.6 Get topic list
createPermissionGroupInCommunity(permissionGroupInfo:succ:fail:)
public func createPermissionGroupInCommunity(permissionGroupInfo: V2TIMPermissionGroupInfo, succ: V2TIMCreatePermissionGroupSucc?, fail: V2TIMFail?)
PermissionGroup
3.1 Create community permission group(supported only in 7.8 and later versions)
-
You need to buy Premium Edition to use this feature.
deletePermissionGroupFromCommunity(groupID:permissionGroupIDList:succ:fail:)
public func deletePermissionGroupFromCommunity(groupID: String, permissionGroupIDList: Array<String>, succ: V2TIMPermissionGroupOperationResultSucc?, fail: V2TIMFail?)
3.2 Delete community permission group(supported only in 7.8 and later versions)
-
You need to buy Premium Edition to use this feature.
modifyPermissionGroupInfoInCommunity(permissionGroupInfo:succ:fail:)
public func modifyPermissionGroupInfoInCommunity(permissionGroupInfo: V2TIMPermissionGroupInfo, succ: V2TIMSucc?, fail: V2TIMFail?)
3.3 Modify community permission group information(supported only in 7.8 and later versions)
-
You need to buy Premium Edition to use this feature.
getJoinedPermissionGroupListInCommunity(groupID:succ:fail:)
public func getJoinedPermissionGroupListInCommunity(groupID: String, succ: @escaping V2TIMPermissionGroupInfoResultListSucc, fail: @escaping V2TIMFail)
3.4 Get joined community permission group list(supported only in 7.8 and later versions)
-
You need to buy Premium Edition to use this feature.
getPermissionGroupListInCommunity(groupID:permissionGroupIDList:succ:fail:)
public func getPermissionGroupListInCommunity(groupID: String, permissionGroupIDList: Array<String>, succ: @escaping V2TIMPermissionGroupInfoResultListSucc, fail: @escaping V2TIMFail)
3.5 Get community permission group list(supported only in 7.8 and later versions)
-
You need to buy Premium Edition to use this feature.
-
When permissionGroupIDList is empty, get all the permission groups; when it is not empty, get the specified permission groups.
addCommunityMembersToPermissionGroup(groupID:permissionGroupID:memberList:succ:fail:)
public func addCommunityMembersToPermissionGroup(groupID: String, permissionGroupID: String, memberList: Array<String>, succ: V2TIMPermissionGroupMemberOperationResultListSucc?, fail: V2TIMFail?)
3.6 Add members to community permission group(supported only in 7.8 and later versions)
-
You need to buy Premium Edition to use this feature.
removeCommunityMembersFromPermissionGroup(groupID:permissionGroupID:memberList:succ:fail:)
public func removeCommunityMembersFromPermissionGroup(groupID: String, permissionGroupID: String, memberList: Array<String>, succ: V2TIMPermissionGroupMemberOperationResultListSucc?, fail: V2TIMFail?)
3.7 Remove members from community permission group(supported only in 7.8 and later versions)
-
You need to buy Premium Edition to use this feature.
getCommunityMemberListInPermissionGroup(groupID:permissionGroupID:nextCursor:succ:fail:)
public func getCommunityMemberListInPermissionGroup(groupID: String, permissionGroupID: String, nextCursor: String, succ: @escaping V2TIMPermissionGroupMemberInfoResultListSucc, fail: @escaping V2TIMFail)
3.8 Get community permission group member list(supported only in 7.8 and later versions)
-
You need to buy Premium Edition to use this feature.
addTopicPermissionToPermissionGroup(groupID:permissionGroupID:topicPermissionMap:succ:fail:)
public func addTopicPermissionToPermissionGroup(groupID: String, permissionGroupID: String, topicPermissionMap: Dictionary<String, NSNumber>, succ: @escaping V2TIMTopicOperationResultSucc, fail: @escaping V2TIMFail)
3.9 Add topic permissions to the permission group(supported only in 7.8 and later versions)
-
You need to buy Premium Edition to use this feature.
deleteTopicPermissionFromPermissionGroup(groupID:permissionGroupID:topicIDList:succ:fail:)
public func deleteTopicPermissionFromPermissionGroup(groupID: String, permissionGroupID: String, topicIDList: Array<String>, succ: @escaping V2TIMTopicOperationResultSucc, fail: @escaping V2TIMFail)
3.10 Delete topic permissions from the permission group(supported only in 7.8 and later versions)
-
You need to buy Premium Edition to use this feature.
modifyTopicPermissionInPermissionGroup(groupID:permissionGroupID:topicPermissionMap:succ:fail:)
public func modifyTopicPermissionInPermissionGroup(groupID: String, permissionGroupID: String, topicPermissionMap: Dictionary<String, NSNumber>, succ: @escaping V2TIMTopicOperationResultSucc, fail: @escaping V2TIMFail)
3.11 Modify the topic permissions in the permission group(supported only in 7.8 and later versions)
-
You need to buy Premium Edition to use this feature.
getTopicPermissionInPermissionGroup(groupID:permissionGroupID:topicIDList:succ:fail:)
public func getTopicPermissionInPermissionGroup(groupID: String, permissionGroupID: String, topicIDList: Array<String>, succ: @escaping V2TIMTopicPermissionResultSucc, fail: @escaping V2TIMFail)
3.12 Get the topic permissions in the permission group(supported only in 7.8 and later versions)
-
You need to buy Premium Edition to use this feature.