copyWith method
PointConnection
copyWith({
- GlobeCoordinates? start,
- GlobeCoordinates? end,
- String? label,
- TextStyle? labelTextStyle,
- String? id,
- Widget? labelBuilder(
- BuildContext context,
- PointConnection pointConnection,
- bool isHovering,
- bool isVisible,
- bool? isMoving,
- bool? isLabelVisible,
- Offset? labelOffset,
- PointConnectionStyle? style,
- VoidCallback? onTap,
- VoidCallback? onHover,
Creates a new PointConnection instance with updated properties.
The start, end, label, labelTextStyle, id, labelBuilder, isMoving, isLabelVisible,
labelOffset, style, onTap, and onHover parameters represent the updated properties of the connection.
Implementation
PointConnection copyWith({
GlobeCoordinates? start,
GlobeCoordinates? end,
String? label,
TextStyle? labelTextStyle,
String? id,
Widget? Function(BuildContext context, PointConnection pointConnection,
bool isHovering, bool isVisible)?
labelBuilder,
bool? isMoving,
bool? isLabelVisible,
Offset? labelOffset,
PointConnectionStyle? style,
VoidCallback? onTap,
VoidCallback? onHover,
}) {
return PointConnection(
start: start ?? this.start,
end: end ?? this.end,
label: label ?? this.label,
labelOffset: labelOffset ?? this.labelOffset,
labelBuilder: labelBuilder ?? this.labelBuilder,
labelTextStyle: labelTextStyle ?? this.labelTextStyle,
id: id ?? this.id,
isMoving: isMoving ?? this.isMoving,
isLabelVisible: isLabelVisible ?? this.isLabelVisible,
style: style ?? this.style,
onTap: onTap ?? this.onTap,
onHover: onHover ?? this.onHover,
);
}