class Cluster {
  final int? id;
  final int? masterId;
  final String? clusterName;
  final int? talkgroup;
  final bool? repeatersOnly;

  Cluster({
    this.id,
    this.masterId,
    this.clusterName,
    this.talkgroup,
    this.repeatersOnly,
  });

  factory Cluster.fromJson(Map<String, dynamic> json) {
    return Cluster(
      id: json['id'] as int?,
      masterId: json['masterId'] as int?,
      clusterName: json['clusterName'] as String?,
      talkgroup: json['talkgroup'] as int?,
      repeatersOnly: json['repeatersOnly'] as bool?,
    );
  }

  Map<String, dynamic> toJson() {
    return {
      'id': id,
      'masterId': masterId,
      'clusterName': clusterName,
      'talkgroup': talkgroup,
      'repeatersOnly': repeatersOnly,
    };
  }
}
