Echo constructor

Echo({
  1. EchoBroadcasterType broadcaster = EchoBroadcasterType.Pusher,
  2. required dynamic client,
  3. Map<String, dynamic>? options,
})

Create a new class instance.

Implementation

Echo({
  EchoBroadcasterType broadcaster = EchoBroadcasterType.Pusher,
  required dynamic client,
  Map<String, dynamic>? options,
}) {
  this.broadcaster = broadcaster;
  this.options = options ?? {};
  this.options['client'] = client;
  this.connect();
}