toJson method

Map<String, dynamic> toJson()

Implementation

Map<String, dynamic> toJson() {
  final json = <String, dynamic>{};
  if (this.id != null) {
    json[r'id'] = this.id;
  } else {
    json[r'id'] = null;
  }
  if (this.eventType != null) {
    json[r'eventType'] = this.eventType;
  } else {
    json[r'eventType'] = null;
  }
  if (this.representationType != null) {
    json[r'representationType'] = this.representationType;
  } else {
    json[r'representationType'] = null;
  }
  if (this.objectType != null) {
    json[r'objectType'] = this.objectType;
  } else {
    json[r'objectType'] = null;
  }
  if (this.objectTypeMapped != null) {
    json[r'objectTypeMapped'] = this.objectTypeMapped;
  } else {
    json[r'objectTypeMapped'] = null;
  }
  if (this.objectId != null) {
    json[r'objectId'] = this.objectId;
  } else {
    json[r'objectId'] = null;
  }
  if (this.objectVersion != null) {
    json[r'objectVersion'] = this.objectVersion;
  } else {
    json[r'objectVersion'] = null;
  }
  if (this.otherObjectType != null) {
    json[r'otherObjectType'] = this.otherObjectType;
  } else {
    json[r'otherObjectType'] = null;
  }
  if (this.otherObjectTypeMapped != null) {
    json[r'otherObjectTypeMapped'] = this.otherObjectTypeMapped;
  } else {
    json[r'otherObjectTypeMapped'] = null;
  }
  if (this.otherObjectId != null) {
    json[r'otherObjectId'] = this.otherObjectId;
  } else {
    json[r'otherObjectId'] = null;
  }
  if (this.context != null) {
    json[r'context'] = this.context;
  } else {
    json[r'context'] = null;
  }
  if (this.subjectName != null) {
    json[r'subjectName'] = this.subjectName;
  } else {
    json[r'subjectName'] = null;
  }
  if (this.created != null) {
    json[r'created'] = this.created!.toUtc().toIso8601String();
  } else {
    json[r'created'] = null;
  }
  if (this.received != null) {
    json[r'received'] = this.received!.toUtc().toIso8601String();
  } else {
    json[r'received'] = null;
  }
  if (this.effectiveDateTime != null) {
    json[r'effectiveDateTime'] = this.effectiveDateTime!.toUtc().toIso8601String();
  } else {
    json[r'effectiveDateTime'] = null;
  }
  return json;
}