store

package
v0.0.0-...-eca62c2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 22, 2022 License: AGPL-3.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type StateStore

type StateStore struct {
	DB     *sql.DB
	Client *mautrix.Client
}

func NewStateStore

func NewStateStore(db *sql.DB) *StateStore

func (*StateStore) CreateTables

func (store *StateStore) CreateTables() error

func (*StateStore) FindSharedRooms

func (store *StateStore) FindSharedRooms(userId mid.UserID) []mid.RoomID

func (*StateStore) GetEncryptionEvent

func (store *StateStore) GetEncryptionEvent(roomId mid.RoomID) *mevent.EncryptionEventContent

func (*StateStore) GetRoomMembers

func (store *StateStore) GetRoomMembers(roomId mid.RoomID) []mid.UserID

func (*StateStore) IsEncrypted

func (store *StateStore) IsEncrypted(roomID mid.RoomID) bool

IsEncrypted returns whether a room is encrypted.

func (*StateStore) LoadFilterID

func (store *StateStore) LoadFilterID(userID mid.UserID) string

func (*StateStore) LoadNextBatch

func (store *StateStore) LoadNextBatch(userID mid.UserID) string

func (*StateStore) LoadRoom

func (store *StateStore) LoadRoom(roomId mid.RoomID) *mautrix.Room

func (*StateStore) SaveFilterID

func (store *StateStore) SaveFilterID(userID mid.UserID, filterID string)

func (*StateStore) SaveNextBatch

func (store *StateStore) SaveNextBatch(userID mid.UserID, nextBatchToken string)

func (*StateStore) SaveRoom

func (store *StateStore) SaveRoom(room *mautrix.Room)

func (*StateStore) SetEncryptionEvent

func (store *StateStore) SetEncryptionEvent(event *mevent.Event)

func (*StateStore) SetMembership

func (store *StateStore) SetMembership(event *mevent.Event)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL