Move history storage to matrix package. Fixes #90
This commit is contained in:
@ -41,7 +41,8 @@ type MatrixContainer interface {
|
||||
JoinRoom(roomID, server string) (*rooms.Room, error)
|
||||
LeaveRoom(roomID string) error
|
||||
|
||||
GetHistory(roomID, prevBatch string, limit int) ([]*mautrix.Event, string, error)
|
||||
GetHistory(room *rooms.Room, limit int) ([]*mautrix.Event, error)
|
||||
GetEvent(room *rooms.Room, eventID string) (*mautrix.Event, error)
|
||||
GetRoom(roomID string) *rooms.Room
|
||||
|
||||
Download(mxcURL string) ([]byte, string, string, error)
|
||||
|
@ -46,7 +46,6 @@ type MainView interface {
|
||||
AddRoom(room *rooms.Room)
|
||||
RemoveRoom(room *rooms.Room)
|
||||
SetRooms(rooms map[string]*rooms.Room)
|
||||
SaveAllHistory()
|
||||
|
||||
UpdateTags(room *rooms.Room)
|
||||
|
||||
@ -67,8 +66,6 @@ const (
|
||||
|
||||
type RoomView interface {
|
||||
MxRoom() *rooms.Room
|
||||
SaveHistory(dir string) error
|
||||
LoadHistory(matrix MatrixContainer, dir string) (int, error)
|
||||
|
||||
SetCompletions(completions []string)
|
||||
SetTyping(users []string)
|
||||
|
Reference in New Issue
Block a user