connect method

Future<void> connect(
  1. String url,
  2. String token,
  3. {ConnectOptions? connectOptions,
  4. RoomOptions? roomOptions,
  5. FastConnectOptions? fastConnectOptions}
)

Implementation

Future<void> connect(
  String url,
  String token, {
  ConnectOptions? connectOptions,
  RoomOptions? roomOptions,
  FastConnectOptions? fastConnectOptions,
}) {
  roomOptions ??= this.roomOptions;
  if (roomOptions.e2eeOptions != null) {
    if (!lkPlatformSupportsE2EE()) {
      throw LiveKitE2EEException('E2EE is not supported on this platform');
    }
    _e2eeManager = E2EEManager(roomOptions.e2eeOptions!.keyProvider);
    _e2eeManager!.setup(this);
  }
  return engine.connect(
    url,
    token,
    connectOptions: connectOptions,
    roomOptions: roomOptions,
    fastConnectOptions: fastConnectOptions,
  );
}