copyWith method

ReportElement copyWith({
  1. String? id,
  2. ReportElementType? type,
  3. double? x,
  4. double? y,
  5. double? width,
  6. double? height,
  7. double? rotation,
  8. int? zIndex,
  9. Map<String, dynamic>? properties,
})

Implementation

ReportElement copyWith({
  String? id,
  ReportElementType? type,
  double? x,
  double? y,
  double? width,
  double? height,
  double? rotation,
  int? zIndex,
  Map<String, dynamic>? properties,
}) {
  return ReportElement(
    id: id ?? this.id,
    type: type ?? this.type,
    x: x ?? this.x,
    y: y ?? this.y,
    width: width ?? this.width,
    height: height ?? this.height,
    rotation: rotation ?? this.rotation,
    zIndex: zIndex ?? this.zIndex,
    properties: properties ?? Map.from(this.properties),
  );
}