of static method

Hometown of({
  1. IReliveItContact? creator,
  2. required DateTime? dateCreated,
  3. ITaskFactForMModel? assistedTask,
  4. required MKey? contactKey,
  5. required IPhysicalLocation? location1,
  6. IPhysicalLocation? location2,
})

Implementation

static Hometown of(
    {IReliveItContact? creator,
    required DateTime? dateCreated,
    ITaskFactForMModel? assistedTask,
    required MKey? contactKey,
    required IPhysicalLocation? location1,
    IPhysicalLocation? location2}) {
  final self =
      Hometown(<String, dynamic>{}, mtype: HometownRef, update: true);
  if (creator != null) self.creator = creator;
  if (dateCreated != null) self.dateCreated = dateCreated;
  if (assistedTask != null) self.assistedTask = assistedTask;
  if (contactKey != null) self.contactKey = contactKey;
  if (location1 != null) self.location1 = location1;
  if (location2 != null) self.location2 = location2;
  return self;
}