Documentation ¶
Index ¶
- Constants
- Variables
- type Member
- type SQLStateStore
- func (store *SQLStateStore) ClearCachedMembers(ctx context.Context, roomID id.RoomID, memberships ...event.Membership) error
- func (store *SQLStateStore) FindSharedRooms(ctx context.Context, userID id.UserID) ([]id.RoomID, error)
- func (store *SQLStateStore) GetEncryptionEvent(ctx context.Context, roomID id.RoomID) (*event.EncryptionEventContent, error)
- func (store *SQLStateStore) GetMember(ctx context.Context, roomID id.RoomID, userID id.UserID) (*event.MemberEventContent, error)
- func (store *SQLStateStore) GetMembership(ctx context.Context, roomID id.RoomID, userID id.UserID) (membership event.Membership, err error)
- func (store *SQLStateStore) GetPowerLevel(ctx context.Context, roomID id.RoomID, userID id.UserID) (int, error)
- func (store *SQLStateStore) GetPowerLevelRequirement(ctx context.Context, roomID id.RoomID, eventType event.Type) (int, error)
- func (store *SQLStateStore) GetPowerLevels(ctx context.Context, roomID id.RoomID) (levels *event.PowerLevelsEventContent, err error)
- func (store *SQLStateStore) GetRoomJoinedOrInvitedMembers(ctx context.Context, roomID id.RoomID) (members []id.UserID, err error)
- func (store *SQLStateStore) GetRoomMembers(ctx context.Context, roomID id.RoomID, memberships ...event.Membership) (map[id.UserID]*event.MemberEventContent, error)
- func (store *SQLStateStore) HasPowerLevel(ctx context.Context, roomID id.RoomID, userID id.UserID, eventType event.Type) (bool, error)
- func (store *SQLStateStore) IsEncrypted(ctx context.Context, roomID id.RoomID) (bool, error)
- func (store *SQLStateStore) IsInRoom(ctx context.Context, roomID id.RoomID, userID id.UserID) bool
- func (store *SQLStateStore) IsInvited(ctx context.Context, roomID id.RoomID, userID id.UserID) bool
- func (store *SQLStateStore) IsMembership(ctx context.Context, roomID id.RoomID, userID id.UserID, ...) bool
- func (store *SQLStateStore) IsRegistered(ctx context.Context, userID id.UserID) (bool, error)
- func (store *SQLStateStore) MarkRegistered(ctx context.Context, userID id.UserID) error
- func (store *SQLStateStore) SetEncryptionEvent(ctx context.Context, roomID id.RoomID, content *event.EncryptionEventContent) error
- func (store *SQLStateStore) SetMember(ctx context.Context, roomID id.RoomID, userID id.UserID, ...) error
- func (store *SQLStateStore) SetMembership(ctx context.Context, roomID id.RoomID, userID id.UserID, ...) error
- func (store *SQLStateStore) SetPowerLevels(ctx context.Context, roomID id.RoomID, levels *event.PowerLevelsEventContent) error
- func (store *SQLStateStore) TryGetMember(ctx context.Context, roomID id.RoomID, userID id.UserID) (*event.MemberEventContent, error)
Constants ¶
View Source
const VersionTableName = "mx_version"
Variables ¶
View Source
var UpgradeTable dbutil.UpgradeTable
Functions ¶
This section is empty.
Types ¶
type SQLStateStore ¶
func NewSQLStateStore ¶
func NewSQLStateStore(db *dbutil.Database, log dbutil.DatabaseLogger, isBridge bool) *SQLStateStore
func (*SQLStateStore) ClearCachedMembers ¶
func (store *SQLStateStore) ClearCachedMembers(ctx context.Context, roomID id.RoomID, memberships ...event.Membership) error
func (*SQLStateStore) FindSharedRooms ¶
func (*SQLStateStore) GetEncryptionEvent ¶
func (store *SQLStateStore) GetEncryptionEvent(ctx context.Context, roomID id.RoomID) (*event.EncryptionEventContent, error)
func (*SQLStateStore) GetMember ¶
func (store *SQLStateStore) GetMember(ctx context.Context, roomID id.RoomID, userID id.UserID) (*event.MemberEventContent, error)
func (*SQLStateStore) GetMembership ¶
func (store *SQLStateStore) GetMembership(ctx context.Context, roomID id.RoomID, userID id.UserID) (membership event.Membership, err error)
func (*SQLStateStore) GetPowerLevel ¶
func (*SQLStateStore) GetPowerLevelRequirement ¶
func (*SQLStateStore) GetPowerLevels ¶
func (store *SQLStateStore) GetPowerLevels(ctx context.Context, roomID id.RoomID) (levels *event.PowerLevelsEventContent, err error)
func (*SQLStateStore) GetRoomJoinedOrInvitedMembers ¶
func (*SQLStateStore) GetRoomMembers ¶
func (store *SQLStateStore) GetRoomMembers(ctx context.Context, roomID id.RoomID, memberships ...event.Membership) (map[id.UserID]*event.MemberEventContent, error)
func (*SQLStateStore) HasPowerLevel ¶
func (*SQLStateStore) IsEncrypted ¶
func (*SQLStateStore) IsMembership ¶
func (store *SQLStateStore) IsMembership(ctx context.Context, roomID id.RoomID, userID id.UserID, allowedMemberships ...event.Membership) bool
func (*SQLStateStore) IsRegistered ¶
func (*SQLStateStore) MarkRegistered ¶
func (*SQLStateStore) SetEncryptionEvent ¶
func (store *SQLStateStore) SetEncryptionEvent(ctx context.Context, roomID id.RoomID, content *event.EncryptionEventContent) error
func (*SQLStateStore) SetMember ¶
func (store *SQLStateStore) SetMember(ctx context.Context, roomID id.RoomID, userID id.UserID, member *event.MemberEventContent) error
func (*SQLStateStore) SetMembership ¶
func (store *SQLStateStore) SetMembership(ctx context.Context, roomID id.RoomID, userID id.UserID, membership event.Membership) error
func (*SQLStateStore) SetPowerLevels ¶
func (store *SQLStateStore) SetPowerLevels(ctx context.Context, roomID id.RoomID, levels *event.PowerLevelsEventContent) error
func (*SQLStateStore) TryGetMember ¶
func (store *SQLStateStore) TryGetMember(ctx context.Context, roomID id.RoomID, userID id.UserID) (*event.MemberEventContent, error)
Click to show internal directories.
Click to hide internal directories.