User class
User of a system impersonating a real person.
- Available extensions
- Annotations
Constructors
-
User(UserId id, UserNum num, {UserName? name, UserBio? bio, UserAvatar? avatar, UserCallCover? callCover, int mutualContactsCount = 0, bool online = false, int? presenceIndex, UserTextStatus? status, bool isDeleted = false, ChatId? dialog, BlocklistRecord? isBlocked, PreciseDateTime? lastSeenAt, List<
NestedChatContact> contacts = const [], WelcomeMessage? welcomeMessage}) -
User.fromJson(Map<
String, dynamic> json) -
Constructs a User from the provided
json
.factory
Properties
- avatar ↔ UserAvatar?
-
Avatar of this User.
getter/setter pair
- bio ↔ UserBio?
-
Arbitrary descriptive information about this User.
getter/setter pair
- callCover ↔ UserCallCover?
-
Call cover of this User.
getter/setter pair
-
contacts
→ List<
NestedChatContact> -
List of NestedChatContacts this User is linked to.
final
- dialog ↔ ChatId
-
Returns ChatId of the Chat-dialog with this User.
getter/setter pair
- hashCode → int
-
The hash code for this object.
no setterinherited
- id → UserId
-
Unique ID of this User.
final
- isBlocked ↔ BlocklistRecord?
-
Indicator whether this User is blocked by the authenticated MyUser.
getter/setter pair
- isDeleted ↔ bool
-
Indicator whether this User is deleted.
getter/setter pair
- lastSeenAt ↔ PreciseDateTime?
-
PreciseDateTime when this User was seen online last time.
getter/setter pair
- mutualContactsCount ↔ int
-
Number of mutual ChatContacts that this User has with the
authenticated MyUser.
getter/setter pair
- name ↔ UserName?
-
Name of this User.
getter/setter pair
- num → UserNum
-
Unique number of this User.
final
- online ↔ bool
-
Online state of this User.
getter/setter pair
- presence ↔ Presence?
-
getter/setter pair
- presenceIndex ↔ int?
-
Presence of this User.
getter/setter pair
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- status ↔ UserTextStatus?
-
Custom text status of this User.
getter/setter pair
- title → String
-
Returns text representing the title of this User.
no setter
- welcomeMessage ↔ WelcomeMessage?
-
WelcomeMessage of this User.
getter/setter pair
Methods
-
getStatus(
[PreciseDateTime? lastSeen]) → String? -
Available on User, provided by the UserViewExt extension
Returns a text represented status of this User based on its User.presence and User.online fields. -
getSubtitle(
[PreciseDateTime? lastSeen]) → String? -
Available on User, provided by the UserViewExt extension
Returns the string representation of this User to display as a subtitle. -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toJson(
) → Map< String, dynamic> - Returns a Map representing this User.
-
toString(
) → String -
A string representation of this object.
override
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited