toJson method

Map<String, dynamic> toJson()

Implementation

Map<String, dynamic> toJson() {
  final awsAccountId = this.awsAccountId;
  final createdAt = this.createdAt;
  final description = this.description;
  final generatorId = this.generatorId;
  final id = this.id;
  final productArn = this.productArn;
  final resources = this.resources;
  final schemaVersion = this.schemaVersion;
  final severity = this.severity;
  final title = this.title;
  final types = this.types;
  final updatedAt = this.updatedAt;
  final compliance = this.compliance;
  final confidence = this.confidence;
  final criticality = this.criticality;
  final firstObservedAt = this.firstObservedAt;
  final lastObservedAt = this.lastObservedAt;
  final malware = this.malware;
  final network = this.network;
  final networkPath = this.networkPath;
  final note = this.note;
  final patchSummary = this.patchSummary;
  final process = this.process;
  final productFields = this.productFields;
  final recordState = this.recordState;
  final relatedFindings = this.relatedFindings;
  final remediation = this.remediation;
  final sourceUrl = this.sourceUrl;
  final threatIntelIndicators = this.threatIntelIndicators;
  final userDefinedFields = this.userDefinedFields;
  final verificationState = this.verificationState;
  final vulnerabilities = this.vulnerabilities;
  final workflow = this.workflow;
  final workflowState = this.workflowState;
  return {
    'AwsAccountId': awsAccountId,
    'CreatedAt': createdAt,
    'Description': description,
    'GeneratorId': generatorId,
    'Id': id,
    'ProductArn': productArn,
    'Resources': resources,
    'SchemaVersion': schemaVersion,
    'Severity': severity,
    'Title': title,
    'Types': types,
    'UpdatedAt': updatedAt,
    if (compliance != null) 'Compliance': compliance,
    if (confidence != null) 'Confidence': confidence,
    if (criticality != null) 'Criticality': criticality,
    if (firstObservedAt != null) 'FirstObservedAt': firstObservedAt,
    if (lastObservedAt != null) 'LastObservedAt': lastObservedAt,
    if (malware != null) 'Malware': malware,
    if (network != null) 'Network': network,
    if (networkPath != null) 'NetworkPath': networkPath,
    if (note != null) 'Note': note,
    if (patchSummary != null) 'PatchSummary': patchSummary,
    if (process != null) 'Process': process,
    if (productFields != null) 'ProductFields': productFields,
    if (recordState != null) 'RecordState': recordState.toValue(),
    if (relatedFindings != null) 'RelatedFindings': relatedFindings,
    if (remediation != null) 'Remediation': remediation,
    if (sourceUrl != null) 'SourceUrl': sourceUrl,
    if (threatIntelIndicators != null)
      'ThreatIntelIndicators': threatIntelIndicators,
    if (userDefinedFields != null) 'UserDefinedFields': userDefinedFields,
    if (verificationState != null)
      'VerificationState': verificationState.toValue(),
    if (vulnerabilities != null) 'Vulnerabilities': vulnerabilities,
    if (workflow != null) 'Workflow': workflow,
    if (workflowState != null) 'WorkflowState': workflowState.toValue(),
  };
}