CallStateReady.fromJson constructor

CallStateReady.fromJson(
  1. Map<String, dynamic> json
)

Parse from a json

Implementation

factory CallStateReady.fromJson(Map<String, dynamic> json) => CallStateReady(
      protocol: CallProtocol.fromJson(json['protocol']),
      servers: List<CallServer>.from((json['servers'] ?? [])
          .map((item) => CallServer.fromJson(item))
          .toList()),
      config: json['config'],
      encryptionKey: json['encryption_key'],
      emojis: List<String>.from(
          (json['emojis'] ?? []).map((item) => item).toList()),
      allowP2p: json['allow_p2p'],
    );