copyWith method

SearchViewArguments copyWith({
  1. List<NeedSearch>? searchData,
  2. String? searchHideText,
  3. void onTap(
    1. BuildContext context,
    2. ChatUIKitProfile profile
    )?,
  4. Widget itemBuilder(
    1. BuildContext context,
    2. ChatUIKitProfile profile,
    3. String? searchKeyword
    )?,
  5. bool? enableMulti,
  6. List<ChatUIKitProfile>? cantChangeSelected,
  7. List<ChatUIKitProfile>? canChangeSelected,
  8. String? selectedTitle,
  9. ChatUIKitViewObserver? viewObserver,
  10. String? attributes,
})

Implementation

SearchViewArguments copyWith({
  List<NeedSearch>? searchData,
  String? searchHideText,
  void Function(BuildContext context, ChatUIKitProfile profile)? onTap,
  Widget Function(BuildContext context, ChatUIKitProfile profile,
          String? searchKeyword)?
      itemBuilder,
  bool? enableMulti,
  List<ChatUIKitProfile>? cantChangeSelected,
  List<ChatUIKitProfile>? canChangeSelected,
  String? selectedTitle,
  ChatUIKitViewObserver? viewObserver,
  String? attributes,
}) {
  return SearchViewArguments(
    searchData: searchData ?? this.searchData,
    searchHideText: searchHideText ?? this.searchHideText,
    onTap: onTap ?? this.onTap,
    itemBuilder: itemBuilder ?? this.itemBuilder,
    enableMulti: enableMulti ?? this.enableMulti,
    cantChangeSelected: cantChangeSelected ?? this.cantChangeSelected,
    canChangeSelected: canChangeSelected ?? this.canChangeSelected,
    selectedTitle: selectedTitle ?? this.selectedTitle,
    viewObserver: viewObserver ?? this.viewObserver,
    attributes: attributes ?? this.attributes,
  );
}