Map<String, dynamic> toJson() { final address = this.address; final portRanges = this.portRanges; return { if (address != null) 'Address': address, if (portRanges != null) 'PortRanges': portRanges, }; }