User class

An object represents user

Implementers
Annotations
  • @JsonSerializable.new()

Constructors

User({required String userId, required String nickname, String? profileUrl, UserConnectionStatus connectionStatus = UserConnectionStatus.notAvailable, int? lastSeenAt, bool? isActive = true, List<String>? preferredLanguages, String? friendDiscoveryKey, String? friendName, List<String>? discoveryKeys, Map<String, String> metaData = const {}, bool requireAuth = false, String? sessionToken})
User.fromJson(Map<String, dynamic> json)
factory

Properties

connectionStatus ↔ UserConnectionStatus
This user's connection status
getter/setter pair
discoveryKeys ↔ List<String>?
getter/setter pair
friendDiscoveryKey ↔ String?
getter/setter pair
friendName ↔ String?
getter/setter pair
hashCode → int
The hash code for this object.
no setteroverride
isActive ↔ bool?
True if this user is activated. This property is changed by the Platform API
getter/setter pair
isCurrentUser → bool
no setter
lastSeenAt ↔ int?
The lastest time when the user became offline
getter/setter pair
metaData ↔ Map<String, String>
getter/setter pair
nickname ↔ String
User nickname
getter/setter pair
preferredLanguages ↔ List<String>?
User's preferred language. Used for translating messages.
getter/setter pair
profileUrl ↔ String?
Profile image url
getter/setter pair
requireAuth ↔ bool
getter/setter pair
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
secureProfileUrl → String?
Profile image url with auth
no setter
sessionToken ↔ String?
getter/setter pair
userId ↔ String
User ID. This has to be unique
getter/setter pair

Methods

copyWith(User other) → void
createMetaData(Map<String, String> metaDataMap) → Future<Map<String, String>>
deleteAllMetaData() → Future<void>
deleteMetaData(String key) → Future<void>
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() → Map<String, dynamic>
toString() → String
A string representation of this object.
inherited
updateMetaData(Map<String, String> metaDataMap) → Future<Map<String, String>>

Operators

operator ==(Object other) → bool
The equality operator.
override