Zone constructor

Zone({
  1. required ResourceType type,
  2. required String id,
  3. String idV1 = "",
  4. required List<Relative> children,
  5. required List<Relative> services,
  6. required RoomMetadata metadata,
})

Creates a Zone object.

Implementation

Zone({
  required super.type,
  required super.id,
  this.idV1 = "",
  required this.children,
  required this.services,
  required this.metadata,
})  : assert(idV1.isEmpty || Validators.isValidIdV1(idV1),
          '"$idV1" is not a valid `idV1`'),
      _originalChildren = children.map((child) => child.copyWith()).toList(),
      _originalMetadata = metadata.copyWith();