copyWith method

PlaceState copyWith({
  1. bool? isShow,
  2. String? queryString,
  3. List<Place>? places,
  4. StatusFetchData? status,
  5. String? error,
})

Creates a copy of the PlaceState with optional modifications.

Implementation

PlaceState copyWith({
  bool? isShow,
  String? queryString,
  List<Place>? places,
  StatusFetchData? status,
  String? error,
}) {
  return PlaceState(
    isShow: isShow ?? this.isShow,
    queryString: queryString ?? this.queryString,
    places: places ?? this.places,
    status: status ?? this.status,
    error: error ?? this.error,
  );
}