ConnectionEvent.fromJson constructor

ConnectionEvent.fromJson(
  1. dynamic json
)

Implementation

factory ConnectionEvent.fromJson(dynamic json) => ConnectionEvent(
      type: json['type'] != null ? json['type'].toString().toConnectionState() : XmppConnectionState.failed,
      error: json["error"] ?? '',
    );