init method

Future<void> init(
  1. ChatOptions options
)

Initializes the SDK.

Param options The configurations: ChatOptions. Ensure that you set this parameter.

Implementation

Future<void> init(ChatOptions options) async {
  _options = options;
  EMLog.v('init: $options');
  await ClientChannel.invokeMethod(ChatMethodKeys.init, options.toJson());
  _currentUserId = await getCurrentUserId();
}