ChatStatisticsSupergroup.fromMap constructor
ChatStatisticsSupergroup.fromMap(
- Map<String, dynamic> map
)
Implementation
ChatStatisticsSupergroup.fromMap(Map<String, dynamic> map) {
extra = map['@extra'];
client_id = map['@client_id'];
if (map['period'] != null) {
period = TdApiMap.fromMap(map['period']) as DateRange;
}
if (map['member_count'] != null) {
member_count = TdApiMap.fromMap(map['member_count']) as StatisticalValue;
}
if (map['message_count'] != null) {
message_count = TdApiMap.fromMap(map['message_count']) as StatisticalValue;
}
if (map['viewer_count'] != null) {
viewer_count = TdApiMap.fromMap(map['viewer_count']) as StatisticalValue;
}
if (map['sender_count'] != null) {
sender_count = TdApiMap.fromMap(map['sender_count']) as StatisticalValue;
}
if (map['member_count_graph'] != null) {
member_count_graph = TdApiMap.fromMap(map['member_count_graph']) as StatisticalGraph;
}
if (map['join_graph'] != null) {
join_graph = TdApiMap.fromMap(map['join_graph']) as StatisticalGraph;
}
if (map['join_by_source_graph'] != null) {
join_by_source_graph = TdApiMap.fromMap(map['join_by_source_graph']) as StatisticalGraph;
}
if (map['language_graph'] != null) {
language_graph = TdApiMap.fromMap(map['language_graph']) as StatisticalGraph;
}
if (map['message_content_graph'] != null) {
message_content_graph = TdApiMap.fromMap(map['message_content_graph']) as StatisticalGraph;
}
if (map['action_graph'] != null) {
action_graph = TdApiMap.fromMap(map['action_graph']) as StatisticalGraph;
}
if (map['day_graph'] != null) {
day_graph = TdApiMap.fromMap(map['day_graph']) as StatisticalGraph;
}
if (map['week_graph'] != null) {
week_graph = TdApiMap.fromMap(map['week_graph']) as StatisticalGraph;
}
if (map['top_senders'] != null) {
top_senders = [];
for (var someValue in map['top_senders']) {
if (someValue != null) {
top_senders?.add(TdApiMap.fromMap(someValue) as ChatStatisticsMessageSenderInfo);
}
}
}
if (map['top_administrators'] != null) {
top_administrators = [];
for (var someValue in map['top_administrators']) {
if (someValue != null) {
top_administrators?.add(TdApiMap.fromMap(someValue) as ChatStatisticsAdministratorActionsInfo);
}
}
}
if (map['top_inviters'] != null) {
top_inviters = [];
for (var someValue in map['top_inviters']) {
if (someValue != null) {
top_inviters?.add(TdApiMap.fromMap(someValue) as ChatStatisticsInviterInfo);
}
}
}
}