Participant class

Participant in a chat room.

Constructors

Participant({required String id, required String userId, required String displayName, String? avatarUrl, ParticipantRole role = ParticipantRole.member, ParticipantStatus status = ParticipantStatus.approved, bool isOnline = false, DateTime? lastSeenAt, DateTime? joinedAt})
Creates a participant.
const

Properties

avatarUrl String?
Avatar URL.
final
displayName String
Display name in this room.
final
hashCode int
The hash code for this object.
no setterinherited
id String
Unique participant ID.
final
isAdmin bool
Whether participant is an admin.
no setter
isApproved bool
Whether participant is approved.
no setter
isOnline bool
Whether currently online.
final
isPending bool
Whether participant is pending.
no setter
joinedAt DateTime?
When user joined the room.
final
lastSeenAt DateTime?
Last seen timestamp.
final
props List<Object?>
The list of properties that will be used to determine whether two instances are equal.
no setter
role ParticipantRole
Role in the room.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
status ParticipantStatus
Membership status.
final
stringify bool?
If set to true, the toString method will be overridden to output this instance's props.
no setterinherited
userId String
User ID.
final

Methods

copyWith({String? id, String? userId, String? displayName, String? avatarUrl, ParticipantRole? role, ParticipantStatus? status, bool? isOnline, DateTime? lastSeenAt, DateTime? joinedAt}) Participant
Creates a copy with updated fields.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited