CometChatUsers class
CometChatUsers is a component that displays a list of users with the help of CometChatListBase and CometChatListItem fetched users are listed down alphabetically and in order of recent activity users are fetched using UsersBuilderProtocol and UsersRequestBuilder
  CometChatUsers(
  usersStyle: UsersStyle(),
);
- Inheritance
- 
    - Object
- DiagnosticableTree
- Widget
- StatefulWidget
- CometChatUsers
 
Constructors
- 
          CometChatUsers({Key? key, UsersBuilderProtocol? usersProtocol, Widget? chatAvatar({String? name, required bool online, Color? rimColor, double? size, required String url})?, Widget? chatConversationItem({required String avatarName, String? avatarUrl, bool? isGroupChat, String? lastAction, bool? online, String? subtitle, DateTime? time, required String title, int? unreadCount})?, Widget? subtitleView(BuildContext, User)?, bool? hideSeparator = true, Widget listItemView(User)?, UsersStyle usersStyle = const UsersStyle(), ScrollController? controller, CometChatTheme? theme, String? searchPlaceholder, Widget? backButton, bool showBackButton = true, Widget? searchBoxIcon, bool hideSearch = false, SelectionMode? selectionMode, dynamic onSelection(List<User> ?, BuildContext)?, String? title, String? errorStateText, String? emptyStateText, dynamic stateCallBack(CometChatUsersController controller)?, UsersRequestBuilder? usersRequestBuilder, bool? hideError, WidgetBuilder? loadingStateView, WidgetBuilder? emptyStateView, WidgetBuilder? errorStateView, ListItemStyle? listItemStyle, List<CometChatOption> ? options(User, CometChatUsersController controller)?, AvatarStyle? avatarStyle, StatusIndicatorStyle? statusIndicatorStyle, List<Widget> appBarOptions(BuildContext context)?, bool? hideSectionSeparator = false, bool? disableUsersPresence, ActivateSelection? activateSelection, OnError? onError, VoidCallback? onBack, dynamic onItemTap(BuildContext context, User)?, dynamic onItemLongPress(BuildContext context, User)?, Widget? selectionIcon, Widget? submitIcon, bool? hideAppbar = false, String? controllerTag})
- 
          
            const
Properties
- activateSelection → ActivateSelection?
- 
  activateSelection lets the widget know if users are allowed to be selected
  final
- 
  appBarOptions
  → List<Widget> Function(BuildContext context)?
- 
  appBarOptions list of options to be visible in app bar
  final
- avatarStyle → AvatarStyle?
- 
  avatarStyle set style for avatar
  final
- backButton → Widget?
- 
  backButton back button
  final
- chatAvatar → Widget? Function({String? name, required bool online, Color? rimColor, double? size, required String url})?
- 
  property to be set internally by using passed parameters usersProtocol ,selectionMode ,options
these are passed to the CometChatUsersController which is responsible for the business logic
CUSTOM WIDGETS
  final
- chatConversationItem → Widget? Function({required String avatarName, String? avatarUrl, bool? isGroupChat, String? lastAction, bool? online, String? subtitle, DateTime? time, required String title, int? unreadCount})?
- 
  
  final
- controller → ScrollController?
- 
  controller sets controller for the list
  final
- controllerTag → String?
- 
  controllerTag tag to create from , if this is passed its parent responsibility to close this
  final
- disableUsersPresence → bool?
- 
  disableUsersPresence controls visibility of status indicator shown if user is online
  final
- emptyStateText → String?
- 
  emptyStateText text to be displayed when the list is empty
  final
- emptyStateView → WidgetBuilder?
- 
  emptyStateView returns view fow empty state
  final
- errorStateText → String?
- 
  errorStateText text to be displayed when error occur
  final
- errorStateView → WidgetBuilder?
- 
  errorStateView returns view fow error state behind the dialog
  final
- hashCode → int
- 
  The hash code for this object.
  no setterinherited
- hideAppbar → bool?
- 
  hideAppbar toggle visibility for app bar
  final
- hideError → bool?
- 
  hideError toggle visibility of error dialog
  final
- hideSearch → bool
- 
  hideSearch switch on/off search input
  final
- hideSectionSeparator → bool?
- 
  hideSeparator toggle visibility of separator
  final
- hideSeparator → bool?
- 
  hideSeparator toggle visibility of separator
  final
- key → Key?
- 
  Controls how one widget replaces another widget in the tree.
  finalinherited
- listItemStyle → ListItemStyle?
- 
  listItemStyle style for every list item
  final
- listItemView → Widget Function(User)?
- 
  listItemView set custom view for each user item
  final
- loadingStateView → WidgetBuilder?
- 
  loadingStateView returns view fow loading state
  final
- onBack → VoidCallback?
- 
  onBack callback triggered on closing this screen
  final
- onError → OnError?
- 
  onError callback triggered in case any error happens when fetching users
  final
- onItemLongPress → dynamic Function(BuildContext context, User)?
- 
  onItemLongPress callback triggered on pressing for long on a user item
  final
- onItemTap → dynamic Function(BuildContext context, User)?
- 
  onItemTap callback triggered on tapping a user item
  final
- 
  onSelection
  → dynamic Function(List<User> ?, BuildContext)?
- 
  onSelection a custom callback that would utilize the selected users to execute some task
  final
- 
  options
  → List<CometChatOption> ? Function(User, CometChatUsersController controller)?
- 
  
  final
- runtimeType → Type
- 
  A representation of the runtime type of the object.
  no setterinherited
- searchBoxIcon → Widget?
- 
  searchBoxIcon search icon
  final
- searchPlaceholder → String?
- 
  searchPlaceholder placeholder text of search input
  final
- selectionIcon → Widget?
- 
  selectionIcon will change selection icon
  final
- selectionMode → SelectionMode?
- 
  selectionMode specifies mode users module is opening in
  final
- showBackButton → bool
- 
  showBackButton switch on/off back button
  final
- stateCallBack → dynamic Function(CometChatUsersController controller)?
- 
  stateCallBack to access controller functions  from parent pass empty reference of  CometChatUsersController object
  final
- statusIndicatorStyle → StatusIndicatorStyle?
- 
  statusIndicatorStyle set style for status indicator
  final
- submitIcon → Widget?
- 
  submitIcon will override the default submit icon
  final
- subtitleView → Widget? Function(BuildContext, User)?
- 
  subtitleView to set subtitle for each user item
  final
- theme → CometChatTheme?
- 
  theme can pass custom theme
  final
- title → String?
- 
  title sets title for the list
  final
- usersProtocol → UsersBuilderProtocol?
- 
  usersProtocol set custom users request builder protocol
  final
- usersRequestBuilder → UsersRequestBuilder?
- 
  usersRequestBuilder custom request builder
  final
- usersStyle → UsersStyle
- 
  usersStyle sets style
  final
Methods
- 
  createElement() → StatefulElement 
- 
  Creates a StatefulElement to manage this widget's location in the tree.
  inherited
- 
  createState() → State< CometChatUsers> 
- 
  Creates the mutable state for this widget at a given location in the tree.
  override
- 
  debugDescribeChildren() → List< DiagnosticsNode> 
- 
  Returns a list of DiagnosticsNode objects describing this node's
children.
  inherited
- 
  debugFillProperties(DiagnosticPropertiesBuilder properties) → void 
- 
  Add additional properties associated with the node.
  inherited
- 
  noSuchMethod(Invocation invocation) → dynamic 
- 
  Invoked when a nonexistent method or property is accessed.
  inherited
- 
  toDiagnosticsNode({String? name, DiagnosticsTreeStyle? style}) → DiagnosticsNode 
- 
  Returns a debug representation of the object that is used by debugging
tools and by DiagnosticsNode.toStringDeep.
  inherited
- 
  toString({DiagnosticLevel minLevel = DiagnosticLevel.info}) → String 
- 
  A string representation of this object.
  inherited
- 
  toStringDeep({String prefixLineOne = '', String? prefixOtherLines, DiagnosticLevel minLevel = DiagnosticLevel.debug, int wrapWidth = 65}) → String 
- 
  Returns a string representation of this node and its descendants.
  inherited
- 
  toStringShallow({String joiner = ', ', DiagnosticLevel minLevel = DiagnosticLevel.debug}) → String 
- 
  Returns a one-line detailed description of the object.
  inherited
- 
  toStringShort() → String 
- 
  A short, textual description of this widget.
  inherited
Operators
- 
  operator ==(Object other) → bool 
- 
  The equality operator.
  inherited