Construct a new User. A User must have an ID and can optionally have extra information associated with it.
The ID of the user.
The info object supplied in the constructor.
The 'displayname' of the user if known.
The 'avatar_url' of the user if known.
The presence enum if known.
The presence status message if known.
The time elapsed in ms since the user interacted proactively with the server, or we saw a message from the user
Timestamp (ms since the epoch) for when we last received presence data for this user. We can subtract lastActiveAgo from this to approximate an absolute value for when a user was last active.
Whether we should consider lastActiveAgo to be an approximation and that the user should be seen as active 'now'
The events describing this user.
The m.presence event for this user.
Required. The ID of this user.
Optional
avatarOptional
displayOptional
presence?: MatrixEventOptional
profile?: MatrixEventPrivate
modifiedOptional
presenceOptional
rawReadonly
userRequired. The ID of this user.
Rest
...args: Parameters<UserEventHandlerMap[T]>Rest
...args: Parameters<UserEventHandlerMap[T]>Optional
event: EventEmitterEvents | UserEventUpdate this User with the given presence event. May fire "User.presence", "User.avatarUrl" and/or "User.displayName" if this event updates this user's properties.
module:client~MatrixClient#event:"User.presence"
module:client~MatrixClient#event:"User.displayName"
module:client~MatrixClient#event:"User.avatarUrl"
The m.presence
event.
Private
updateGenerated using TypeDoc
Typed Event Emitter class which can act as a Base Model for all our model and communication events. This makes it much easier for us to distinguish between events, as we now need to properly type this, so that our events are not stringly-based and prone to silly typos.