fromJson static method
Inherited by: ChatStatisticsObjectTypeMessage ChatStatisticsObjectTypeStory
Implementation
static ChatStatisticsObjectType? fromJson(Map<String, dynamic>? json) {
if (json == null) {
return null;
}
switch (json['@type']) {
case ChatStatisticsObjectTypeMessage.constructor:
return ChatStatisticsObjectTypeMessage.fromJson(json);
case ChatStatisticsObjectTypeStory.constructor:
return ChatStatisticsObjectTypeStory.fromJson(json);
default:
return null;
}
}