factory FilterRule.fromJson(Map<String, dynamic> json) { return FilterRule( filterType: (json['FilterType'] as String?)?.toFilterType(), value: json['Value'] as String?, ); }