copyWith method

  1. @override
InlineQueryResultLocation copyWith({
  1. String? id,
  2. Location? location,
  3. String? title,
  4. Thumbnail? thumbnail()?,
})
override

Returns a copy with the given fields replaced. For a nullable field pass a function, e.g. field: () => null to clear it.

Implementation

@override
InlineQueryResultLocation copyWith({
  String? id,
  Location? location,
  String? title,
  Thumbnail? Function()? thumbnail,
}) =>
    InlineQueryResultLocation(
      id: id ?? this.id,
      location: location ?? this.location,
      title: title ?? this.title,
      thumbnail: thumbnail != null ? thumbnail() : this.thumbnail,
    );