initGroupAttributes method Null safety

Future<V2TimCallback> initGroupAttributes(
  1. {required String groupID,
  2. required Map<String, String> attributes}
)

This interface has been moved to messageManager, 2020-6-4 Modify group message receiving options

Parameter

opt	Three types of message receiving options: ReceiveMsgOptEnum.V2TIM_GROUP_RECEIVE_MESSAGE: normally receive messages online, offline push notifications from manufacturers will be available when offline ReceiveMsgOptEnum.V2TIM_GROUP_NOT_RECEIVE_MESSAGE: will not receive group messages There will be push notifications

Initialize group attributes. This will clear the existing group attribute list.

Note:

Use limits of attributes:

1. Currently only supports AVChatRoom
2, the key supports up to 16, the length is limited to 32 bytes
3, the value length is limited to 4k
4, the total attributes (including key and value) are limited to 16k
5, initGroupAttributes, setGroupAttributes , deleteGroupAttributes interface combined calculation, the SDK limit is 10 times in 5 seconds, and the error code 8511 will be called back after exceeding it; the background limit is 5 times in 1 second, and the error code 10049 will be returned after exceeding it.
6, The SDK limit of getGroupAttributes interface is 20 times in 5 seconds

Implementation

// Future<V2TimCallback> setReceiveMessageOpt({
// required String groupID,
// required int opt,
// }) async {
// return V2TimCallback.fromJson(
// formatJson(
// await _channel.invokeMethod(
/&# 47; "setReceiveMessageOpt",
// buildParam(
// {
// "groupID": groupID,
/& #47; "opt": opt,
// },
// ),
// ),
/&# 47; ),
// );
// }

/// Initialize the group attribute, it will clear the original group Property List
///
/// Note
///
// ;/ The use of attributes is restricted as follows:
///
/// ```
//& #47; 1. Currently only supports AVChatRoom
/// 2. The key supports up to 16, and the length is limited to 32 bytes
/// 3 , The value length is limited to 4k
/// 4. The total attributes (including key and value) are limited to 16k
/// 5. initGroupAttributes, setGroupAttributes, delete The eGroupAttributes interface is combined and calculated, the SDK limit is 10 times in 5 seconds, and the 8511 error code will be called back when it exceeds; the background limit is 5 times in 1 second, and the error code 10049 will be returned after it exceeds
/// 6. getGroupAttributes interface SDK limit 20 times per 5 seconds
/// ```
Future<V2TimCallback> initGroupAttributes({
 required String groupID,
 required Map<String, String> attributes,
} ) async {
 return ImFlutterPlatform.instance
 .initGroupAttributes(groupID: groupID, attributes: attributes);
}