Internal
The matrix client instance to use.
Optional
opts: IStoredClientOptsclient config options
Optional
syncOpts: SyncApiOptionssync-specific options passed by the client
Private
_peekPrivate
Optional
abortPrivate
catchingPrivate
Readonly
clientThe matrix client instance to use.
Private
Optional
connectionPrivate
Optional
currentPrivate
failedPrivate
Optional
keepPrivate
notifPrivate
Readonly
optsPrivate
Optional
presencePrivate
runningPrivate
Optional
savedPrivate
storePrivate
Readonly
syncPrivate
syncPrivate
Optional
syncPrivate
buildPrivate
checkPrivate
doInvoke me to do /sync calls
Private
doPrivate
findOptional
events: MatrixEvent[]Private
getPrivate
getPrivate
getPrivate
getReturns the additional data object associated with the current sync state, or null if there is no such data. Sync errors, if available, are put in the 'error' key of this object.
Injects events into a room's model.
A list of state events. This is the state at the START of the timeline list if it is supplied.
Optional
timelineEventList: MatrixEvent[]A list of timeline events, including threaded. Lower index is earlier in time. Higher index is later.
whether the sync response came from cache
Private
isOptional
timelineEventList: MatrixEvent[]Private
mapOptional
room: RoomPrivate
mapPrivate
onWhen we see the marker state change in the room, we know there is some
new historical messages imported by MSC2716 /batch_send
somewhere in
the room and we need to throw away the timeline to make sure the
historical messages are shown when we paginate /messages
again.
The room where the marker event was sent
The new marker event
When timelineWasEmpty
is set
as true
, the given marker event will be ignored
Private
onPrivate
onPeek into a room. This will result in the room in question being synced so it is accessible via getRooms(). Live updates for the room will be provided.
The room ID to peek into.
A promise which resolves once the room has been added to the store.
Private
peekDo a peek room poll.
Optional
token: stringfrom= token
Private
pokeMake a dummy call to /_matrix/client/versions, to see if the HS is reachable.
On failure, schedules a call back to itself. On success, resolves this.connectionReturnedDefer.
True if a connectivity failure has been detected. Optional.
Private
processTakes a list of timelineEvents and adds and adds to notifEvents as appropriate. This must be called after the room the events belong to has been stored.
A list of timeline events. Lower index is earlier in time. Higher index is later.
Private
processProcess data returned from a sync response and propagate it into the model objects
Object containing sync tokens associated with this sync
The response from /sync
Private
resolveSpecify the set_presence value to be used for subsequent calls to the Sync API.
Optional
presence: SetPresencethe presence to specify to set_presence of sync calls
Private
shouldPrivate
startStarts polling the connectivity check endpoint
Optional
delay: numberHow long to delay until the first poll. defaults to a short, randomised interval (to prevent tight-looping if /versions succeeds but /sync etc. fail).
which resolves once the connection returns
Private
syncProcess a single set of cached sync data.
a saved sync that was persisted by a store. This should have been acquired via client.store.getSavedSync().
Private
updateSets the sync state and emits an event to say so
The new state string
Optional
data: SyncStateDataObject of additional data to emit in the event
Private
wasGenerated using TypeDoc
Construct an entity which is able to sync with a homeserver.