toJson method

Map<String, dynamic> toJson()

Implementation

Map<String, dynamic> toJson() {
  final sizePercent = this.sizePercent;
  final customDeliveryConfiguration = this.customDeliveryConfiguration;
  final messageConfiguration = this.messageConfiguration;
  final schedule = this.schedule;
  final templateConfiguration = this.templateConfiguration;
  final treatmentDescription = this.treatmentDescription;
  final treatmentName = this.treatmentName;
  return {
    'SizePercent': sizePercent,
    if (customDeliveryConfiguration != null)
      'CustomDeliveryConfiguration': customDeliveryConfiguration,
    if (messageConfiguration != null)
      'MessageConfiguration': messageConfiguration,
    if (schedule != null) 'Schedule': schedule,
    if (templateConfiguration != null)
      'TemplateConfiguration': templateConfiguration,
    if (treatmentDescription != null)
      'TreatmentDescription': treatmentDescription,
    if (treatmentName != null) 'TreatmentName': treatmentName,
  };
}