copyWith method
Creates a copy of this segment with the given fields replaced.
Implementation
WheelSegment<T> copyWith({
String? label,
T? value,
Color? color,
String? path,
ImageProvider? imageProvider,
ui.Image? image,
Widget? child,
TextStyle? textStyle,
String? semanticLabel,
double? probability,
}) {
return WheelSegment<T>(
label ?? this.label,
value ?? this.value,
color: color ?? this.color,
path: path ?? this.path,
imageProvider: imageProvider ?? this.imageProvider,
image: image ?? this.image,
child: child ?? this.child,
textStyle: textStyle ?? this.textStyle,
semanticLabel: semanticLabel ?? this.semanticLabel,
probability: probability ?? this.probability,
);
}