|
void | checkVersion () |
|
QString | postMessage (const QString &plainText, MessageEventType type) |
|
QString | postPlainText (const QString &plainText) |
|
QString | postHtmlMessage (const QString &plainText, const QString &html, MessageEventType type=MessageEventType::Text) |
|
QString | postHtmlText (const QString &plainText, const QString &html) |
|
QString | postReaction (const QString &eventId, const QString &key) |
| Send a reaction on a given event with a given key.
|
|
QString | postEvent (RoomEvent *event) |
|
QString | postJson (const QString &matrixType, const QJsonObject &eventContent) |
|
QString | retryMessage (const QString &txnId) |
|
void | discardMessage (const QString &txnId) |
|
SetRoomStateWithKeyJob * | setState (const QString &evtType, const QString &stateKey, const QJsonObject &contentJson) |
| Send a request to update the room state based on freeform inputs.
|
|
void | setName (const QString &newName) |
|
void | setCanonicalAlias (const QString &newAlias) |
|
void | setPinnedEvents (const QStringList &events) |
|
void | setLocalAliases (const QStringList &aliases) |
| Set room aliases on the user's current server.
|
|
void | setTopic (const QString &newTopic) |
|
void | refreshDisplayName () |
| You shouldn't normally call this method; it's here for debugging.
|
|
JobHandle< GetRoomEventsJob > | getPreviousContent (int limit=10, const QString &filter={}) |
|
void | inviteToRoom (const QString &memberId) |
|
JobHandle< LeaveRoomJob > | leaveRoom () |
|
void | kickMember (const QString &memberId, const QString &reason={}) |
|
void | ban (const QString &userId, const QString &reason={}) |
|
void | unban (const QString &userId) |
|
void | redactEvent (const QString &eventId, const QString &reason={}) |
|
void | uploadFile (const QString &id, const QUrl &localFilename, const QString &overrideContentType={}) |
|
void | downloadFile (const QString &eventId, const QUrl &localFilename={}) |
|
void | cancelFileTransfer (const QString &id) |
|
void | setReadReceipt (const QString &atEventId) |
| Set a given event as last read and post a read receipt on it.
|
|
void | markAllMessagesAsRead () |
| Put the fully-read marker at the latest message in the room.
|
|
void | switchVersion (QString newVersion) |
| Switch the room's version (aka upgrade)
|
|
void | inviteCall (const QString &callId, const int lifetime, const QString &sdp) |
|
void | sendCallCandidates (const QString &callId, const QJsonArray &candidates) |
|
void | answerCall (const QString &callId, const QString &sdp) |
|
void | hangupCall (const QString &callId) |
|
void | activateEncryption () |
|
|
void | baseStateLoaded () |
| Initial set of state events has been loaded.
|
|
void | eventsHistoryJobChanged () |
|
void | aboutToAddHistoricalMessages (Quotient::RoomEventsRange events) |
|
void | aboutToAddNewMessages (Quotient::RoomEventsRange events) |
|
void | addedMessages (int fromIndex, int toIndex) |
|
void | pendingEventAboutToAdd (Quotient::RoomEvent *event) |
| The event is about to be appended to the list of pending events.
|
|
void | pendingEventAdded (const Quotient::RoomEvent *event) |
| An event has been appended to the list of pending events.
|
|
void | pendingEventAboutToMerge (Quotient::RoomEvent *serverEvent, int pendingEventIndex) |
|
void | pendingEventMerged () |
| The remote and local copies of the event have been merged.
|
|
void | pendingEventAboutToDiscard (int pendingEventIndex) |
| An event will be removed from the list of pending events.
|
|
void | pendingEventDiscarded () |
| An event has just been removed from the list of pending events.
|
|
void | pendingEventChanged (int pendingEventIndex) |
| The status of a pending event has changed.
|
|
void | messageSent (QString txnId, QString eventId) |
| The server accepted the message.
|
|
void | changed (Quotient::Room::Changes changes) |
|
void | namesChanged (Quotient::Room *room) |
| The room name, the canonical alias or other aliases changed.
|
|
void | displaynameAboutToChange (Quotient::Room *room) |
|
void | displaynameChanged (Quotient::Room *room, QString oldName) |
|
void | pinnedEventsChanged () |
|
void | topicChanged () |
|
void | avatarChanged () |
|
void | memberJoined (RoomMember member) |
| A new member has joined the room.
|
|
void | memberLeft (RoomMember member) |
| A member who previously joined has left.
|
|
void | memberNameAboutToUpdate (RoomMember member, QString newName) |
| A known joined member is about to update their display name.
|
|
void | memberNameUpdated (RoomMember member) |
| A known joined member has updated their display name.
|
|
void | memberAvatarUpdated (RoomMember member) |
| A known joined member has updated their avatar.
|
|
void | memberListChanged () |
| The list of members has changed.
|
|
void | allMembersLoaded () |
|
void | encryption () |
|
void | joinStateChanged (Quotient::JoinState oldState, Quotient::JoinState newState) |
|
void | typingChanged () |
| The list of members sending typing indicators has changed.
|
|
void | highlightCountChanged () |
|
void | notificationCountChanged () |
|
void | displayedChanged (bool displayed) |
|
void | firstDisplayedEventChanged () |
|
void | lastDisplayedEventChanged () |
|
void | lastReadEventChanged (QVector< QString > userIds) |
|
void | fullyReadMarkerMoved (QString fromEventId, QString toEventId) |
|
void | partiallyReadStatsChanged () |
|
void | unreadStatsChanged () |
|
void | allHistoryLoadedChanged () |
|
void | accountDataAboutToChange (QString type) |
|
void | accountDataChanged (QString type) |
|
void | tagsAboutToChange () |
|
void | tagsChanged () |
|
void | updatedEvent (QString eventId) |
|
void | replacedEvent (const Quotient::RoomEvent *newEvent, const Quotient::RoomEvent *oldEvent) |
|
void | newFileTransfer (QString id, QUrl localFile) |
|
void | fileTransferProgress (QString id, qint64 progress, qint64 total) |
|
void | fileTransferCompleted (QString id, QUrl localFile, FileSourceInfo fileMetadata) |
|
void | fileTransferFailed (QString id, QString errorMessage={}) |
|
void | callEvent (Quotient::Room *room, const Quotient::RoomEvent *event) |
|
void | stabilityUpdated (QString recommendedDefault, QStringList stableVersions) |
| The room's version stability may have changed.
|
|
void | upgraded (QString serverMessage, Quotient::Room *successor) |
| This room has been upgraded and won't receive updates any more.
|
|
void | upgradeFailed (QString errorMessage) |
| An attempted room upgrade has failed.
|
|
void | beforeDestruction (Quotient::Room *) |
| The room is about to be deleted.
|
|
|
| Room (Connection *connection, QString id, JoinState initialJoinState) |
|
| ~Room () override |
|
Connection * | connection () const |
|
RoomMember | localMember () const |
| Get a RoomMember object for the local user.
|
|
const QString & | id () const |
|
QString | version () const |
|
bool | isUnstable () const |
|
QString | predecessorId () const |
|
Room * | predecessor (JoinStates statesFilter=JoinState::Invite|JoinState::Join) const |
| Room predecessor.
|
|
QString | successorId () const |
|
Room * | successor (JoinStates statesFilter=JoinState::Invite|JoinState::Join) const |
| Room successor.
|
|
QString | name () const |
|
QString | canonicalAlias () const |
|
QStringList | altAliases () const |
|
QStringList | aliases () const |
| Get a list of both canonical and alternative aliases.
|
|
QString | displayName () const |
|
QStringList | pinnedEventIds () const |
|
QVector< const RoomEvent * > | pinnedEvents () const |
|
QString | displayNameForHtml () const |
|
QString | topic () const |
|
QString | avatarMediaId () const |
|
QUrl | avatarUrl () const |
|
const Avatar & | avatarObject () const |
|
Q_INVOKABLE JoinState | joinState () const |
|
int | timelineSize () const |
|
bool | usesEncryption () const |
|
RoomEventPtr | decryptMessage (const EncryptedEvent &encryptedEvent) |
|
void | handleRoomKeyEvent (const RoomKeyEvent &roomKeyEvent, const QString &senderId, const QByteArray &olmSessionId, const QByteArray &senderKey, const QByteArray &senderEdKey) |
|
int | joinedCount () const |
|
int | invitedCount () const |
|
int | totalMemberCount () const |
|
GetRoomEventsJob * | eventsHistoryJob () const |
|
Q_INVOKABLE QImage | avatar (int dimension) |
|
Q_INVOKABLE QImage | avatar (int width, int height) |
|
Q_INVOKABLE RoomMember | member (const QString &userId) const |
| Get a RoomMember object for the given user Matrix ID.
|
|
QList< RoomMember > | joinedMembers () const |
| Get a list of room members who have joined the room.
|
|
QList< RoomMember > | members () const |
| Get a list of all members known to the room.
|
|
QList< RoomMember > | membersLeft () const |
| Get a list of all members known to have left the room.
|
|
QList< RoomMember > | membersTyping () const |
| Get a list of room members who are currently sending a typing indicator.
|
|
QList< RoomMember > | otherMembersTyping () const |
| Get a list of room members who are currently sending a typing indicator.
|
|
QStringList | joinedMemberIds () const |
| Get a list of room member Matrix IDs who have joined the room.
|
|
QStringList | memberIds () const |
| Get a list of all member Matrix IDs known to the room.
|
|
bool | needsDisambiguation (const QString &userId) const |
| Whether the name for the given member should be disambiguated.
|
|
Q_INVOKABLE Quotient::Membership | memberState (const QString &userId) const |
| Check the join state of a given user in this room.
|
|
Q_INVOKABLE bool | isMember (const QString &userId) const |
| Check whether a user with the given id is a member of the room.
|
|
const Avatar & | memberAvatarObject (const QString &memberId) const |
|
Q_INVOKABLE QImage | memberAvatar (const QString &memberId, int width, int height) |
| Get a avatar of the specified dimensions.
|
|
Q_INVOKABLE QImage | memberAvatar (const QString &memberId, int dimension) |
| Get a square avatar of the specified size.
|
|
const Timeline & | messageEvents () const |
|
const PendingEvents & | pendingEvents () const |
|
int | requestedHistorySize () const |
| Get the number of requested historical events.
|
|
bool | allHistoryLoaded () const |
|
rev_iter_t | historyEdge () const |
| Get a reverse iterator at the position before the "oldest" event.
|
|
const ThreadView & | threads () const |
|
Timeline::const_iterator | syncEdge () const |
| Get an iterator for the position beyond the latest arrived event.
|
|
Q_INVOKABLE Quotient::TimelineItem::index_t | minTimelineIndex () const |
|
Q_INVOKABLE Quotient::TimelineItem::index_t | maxTimelineIndex () const |
|
Q_INVOKABLE bool | isValidIndex (Quotient::TimelineItem::index_t timelineIndex) const |
|
rev_iter_t | findInTimeline (TimelineItem::index_t index) const |
|
rev_iter_t | findInTimeline (const QString &evtId) const |
|
PendingEvents::iterator | findPendingEvent (const QString &txnId) |
|
PendingEvents::const_iterator | findPendingEvent (const QString &txnId) const |
|
const RelatedEvents | relatedEvents (const QString &evtId, EventRelation::reltypeid_t relType) const |
|
const RelatedEvents | relatedEvents (const RoomEvent &evt, EventRelation::reltypeid_t relType) const |
|
const RoomCreateEvent * | creation () const |
|
const RoomTombstoneEvent * | tombstone () const |
|
bool | displayed () const |
|
void | setDisplayed (bool displayed=true) |
| Mark the room as currently displayed to the user.
|
|
QString | firstDisplayedEventId () const |
|
rev_iter_t | firstDisplayedMarker () const |
|
void | setFirstDisplayedEventId (const QString &eventId) |
|
void | setFirstDisplayedEvent (TimelineItem::index_t index) |
|
QString | lastDisplayedEventId () const |
|
rev_iter_t | lastDisplayedMarker () const |
|
void | setLastDisplayedEventId (const QString &eventId) |
|
void | setLastDisplayedEvent (TimelineItem::index_t index) |
|
ReadReceipt | lastReadReceipt (const QString &userId) const |
| Get the latest read receipt from a user.
|
|
ReadReceipt | lastLocalReadReceipt () const |
| Get the latest read receipt from the local user.
|
|
rev_iter_t | localReadReceiptMarker () const |
| Find the timeline item the local read receipt is at.
|
|
QString | lastFullyReadEventId () const |
| Get the latest event id marked as fully read.
|
|
rev_iter_t | fullyReadMarker () const |
| Get the iterator to the latest timeline item marked as fully read.
|
|
QSet< QString > | userIdsAtEvent (const QString &eventId) const |
| Get users whose latest read receipts point to the event.
|
|
Q_INVOKABLE void | markMessagesAsRead (const QString &uptoEventId) |
| Mark the event with uptoEventId as fully read.
|
|
virtual bool | isEventNotable (const TimelineItem &ti) const |
| Determine whether an event should be counted as unread.
|
|
Notification | notificationFor (const TimelineItem &ti) const |
| Get notification details for an event.
|
|
EventStats | partiallyReadStats () const |
| Get event statistics since the fully read marker.
|
|
EventStats | unreadStats () const |
| Get event statistics since the last read receipt.
|
|
qsizetype | notificationCount () const |
| Get the number of notifications since the last read receipt.
|
|
qsizetype | highlightCount () const |
| Get the number of highlights since the last read receipt.
|
|
bool | hasAccountData (const QString &type) const |
|
const EventPtr & | accountData (const QString &type) const |
|
QStringList | accountDataEventTypes () const |
|
QStringList | tagNames () const |
|
TagsMap | tags () const |
|
Tag | tag (const QString &name) const |
|
void | addTag (const QString &name, const Tag &tagData={}) |
|
Q_INVOKABLE void | addTag (const QString &name, float order) |
|
Q_INVOKABLE void | removeTag (const QString &name) |
| Remove a tag from the room.
|
|
void | setTags (TagsMap newTags, ActionScope applyOn=ThisRoomOnly) |
|
bool | isFavourite () const |
| Check whether the list of tags has m.favourite.
|
|
bool | isLowPriority () const |
| Check whether the list of tags has m.lowpriority.
|
|
bool | isServerNoticeRoom () const |
| Check whether this room is for server notices (MSC1452)
|
|
Q_INVOKABLE bool | isDirectChat () const |
| Check whether this room is a direct chat.
|
|
QList< RoomMember > | directChatMembers () const |
| Get the list of members this room is a direct chat with.
|
|
Q_INVOKABLE QUrl | makeMediaUrl (const QString &eventId, const QUrl &mxcUrl) const |
|
Q_INVOKABLE QUrl | urlToThumbnail (const QString &eventId) const |
|
Q_INVOKABLE QUrl | urlToDownload (const QString &eventId) const |
|
Q_INVOKABLE QString | fileNameToDownload (const QString &eventId) const |
| Get a file name for downloading for a given event id.
|
|
Q_INVOKABLE Quotient::FileTransferInfo | fileTransferInfo (const QString &id) const |
| Get information on file upload/download.
|
|
Q_INVOKABLE QUrl | fileSource (const QString &id) const |
| Get the URL to the actual file source in a unified way.
|
|
Q_INVOKABLE QString | prettyPrint (const QString &plainText) const |
|
MemberSorter | memberSorter () const |
|
Q_INVOKABLE bool | supportsCalls () const |
|
Q_INVOKABLE bool | canSwitchVersions () const |
| Whether the current user is allowed to upgrade the room.
|
|
RoomStateView | currentState () const |
| Get the current room state.
|
|
Q_INVOKABLE int | memberEffectivePowerLevel (const QString &memberId={}) const |
| The effective power level of the given member in the room.
|
|
Q_INVOKABLE int | powerLevelFor (const QString &eventTypeId, bool forceStateEvent=false) const |
| Get the power level required to send events of the given type.
|
|
template<EventClass EvT> |
int | powerLevelFor () const |
| Get the power level required to send events of the given type.
|
|
const PendingEventItem & | post (RoomEventPtr event) |
| Post a pre-created room message event.
|
|
template<typename EvT , typename... ArgTs> |
const PendingEventItem & | post (ArgTs &&... args) |
|
QString | postFile (const QString &plainText, std::unique_ptr< EventContent::FileContentBase > fileContent) |
|
PendingEventItem::future_type | whenMessageMerged (QString txnId) const |
|
SetRoomStateWithKeyJob * | setState (const StateEvent &evt) |
| Send a request to update the room state with the given event.
|
|
template<typename EvT , typename... ArgTs> |
auto | setState (ArgTs &&... args) |
| Set a state event of the given type with the given arguments.
|
|
void | addMegolmSessionFromBackup (const QByteArray &sessionId, const QByteArray &sessionKey, uint32_t index, const QByteArray &senderKey, const QByteArray &senderEdKey) |
|
Q_INVOKABLE void | startVerification () |
|
QJsonArray | exportMegolmSessions () |
|
Definition at line 118 of file room.h.